From 16df533a31ad946587172d14d8c754a84c885c56 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=A8?= Date: Fri, 15 May 2026 16:20:01 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E6=B7=BB=E5=8A=A0=E9=A6=96=E9=A1=B5?= =?UTF-8?q?=E7=BB=9F=E8=AE=A1=E6=95=B0=E6=8D=AE=E6=8E=A5=E5=8F=A3=E5=AF=B9?= =?UTF-8?q?=E6=8E=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/modules/dashboard.ts | 15 +++++++++ src/views/dashboard/index.vue | 61 +++++++++++++++++++++++++---------- 2 files changed, 59 insertions(+), 17 deletions(-) diff --git a/src/api/modules/dashboard.ts b/src/api/modules/dashboard.ts index 12ea0f8..3fdddb1 100644 --- a/src/api/modules/dashboard.ts +++ b/src/api/modules/dashboard.ts @@ -15,3 +15,18 @@ export const editAccountPass = (params: any) => { return request.post('/user/editAccountPass', { ...params }) } +// 获取首页统计数据 +export interface DashboardData { + agent_count: number + user_count: number + today_user_count: number + today_recharge_amount: string + today_withdraw_amount: number + total_recharge_amount: number + total_withdraw_amount: number +} + +export async function getUserIndex(): Promise { + return await request.get('/user/index') +} + diff --git a/src/views/dashboard/index.vue b/src/views/dashboard/index.vue index 7ee5060..f62be96 100644 --- a/src/views/dashboard/index.vue +++ b/src/views/dashboard/index.vue @@ -15,31 +15,58 @@ -