@@ -31,7 +31,7 @@ func GetWithdrawSetting(c *gin.Context) { | |||
return | |||
} | |||
// 不存在则初始化 | |||
var emptyNum []int | |||
var emptyNum []string | |||
if setting == nil { | |||
now := time.Now() | |||
frequency := md2.WithdrawFrequencySettingStruct{ | |||
@@ -12,6 +12,15 @@ import ( | |||
"time" | |||
) | |||
type TotalDataResp struct { | |||
TotalUserCount int `json:"total_user_count"` // 平台总用户数 | |||
VerifiedUserCount int `json:"verified_user_count"` // 已认证用户数 | |||
NoSignInUserCount int `json:"no_sign_in_user_count"` // 未签到用户数 | |||
TotalWithdrawAmount string `json:"total_withdraw_amount"` //已提现累计金额 | |||
Year string `json:"year"` // 年份 | |||
Month string `json:"month"` // 月份 | |||
} | |||
// GetTotalData | |||
// @Summary 首页-首页-数据总览 | |||
// @Tags 首页 | |||
@@ -21,7 +30,7 @@ import ( | |||
// @param Authorization header string true "验证参数Bearer和token空格拼接" | |||
// @Param year query string true "年" | |||
// @Param month query string true "月" | |||
// @Success 200 {object} model.PlatformTotalData "具体数据" | |||
// @Success 200 {object} TotalDataResp "具体数据" | |||
// @Failure 400 {object} md.Response "具体错误" | |||
// @Router /api/homePage/totalData [GET] | |||
func GetTotalData(c *gin.Context) { | |||
@@ -38,7 +47,15 @@ func GetTotalData(c *gin.Context) { | |||
e.OutErr(c, e.ERR_DB_ORM, err.Error()) | |||
return | |||
} | |||
e.OutSuc(c, data, nil) | |||
resp := TotalDataResp{ | |||
TotalUserCount: data.TotalUserCount, | |||
VerifiedUserCount: data.VerifiedUserCount, | |||
NoSignInUserCount: data.NoSignInUserCount, | |||
TotalWithdrawAmount: data.TotalWithdrawAmount, | |||
Year: data.Year, | |||
Month: data.Month, | |||
} | |||
e.OutSuc(c, resp, nil) | |||
} | |||
type GetActiveDataResp struct { | |||
@@ -1625,7 +1625,7 @@ const docTemplate = `{ | |||
"200": { | |||
"description": "具体数据", | |||
"schema": { | |||
"$ref": "#/definitions/model.PlatformTotalData" | |||
"$ref": "#/definitions/hdl.TotalDataResp" | |||
} | |||
}, | |||
"400": { | |||
@@ -6651,6 +6651,35 @@ const docTemplate = `{ | |||
} | |||
} | |||
}, | |||
"hdl.TotalDataResp": { | |||
"type": "object", | |||
"properties": { | |||
"month": { | |||
"description": "月份", | |||
"type": "string" | |||
}, | |||
"no_sign_in_user_count": { | |||
"description": "未签到用户数", | |||
"type": "integer" | |||
}, | |||
"total_user_count": { | |||
"description": "平台总用户数", | |||
"type": "integer" | |||
}, | |||
"total_withdraw_amount": { | |||
"description": "已提现累计金额", | |||
"type": "string" | |||
}, | |||
"verified_user_count": { | |||
"description": "已认证用户数", | |||
"type": "integer" | |||
}, | |||
"year": { | |||
"description": "年份", | |||
"type": "string" | |||
} | |||
} | |||
}, | |||
"md.ActivePointsWalletNode": { | |||
"type": "object", | |||
"properties": { | |||
@@ -7608,6 +7637,9 @@ const docTemplate = `{ | |||
"os": { | |||
"type": "string" | |||
}, | |||
"platform": { | |||
"type": "string" | |||
}, | |||
"src": { | |||
"type": "string" | |||
}, | |||
@@ -7644,6 +7676,12 @@ const docTemplate = `{ | |||
"last_is_combine": { | |||
"type": "string" | |||
}, | |||
"last_platform": { | |||
"type": "array", | |||
"items": { | |||
"type": "string" | |||
} | |||
}, | |||
"list": { | |||
"type": "array", | |||
"items": { | |||
@@ -7653,6 +7691,12 @@ const docTemplate = `{ | |||
"list_ios": { | |||
"type": "string" | |||
}, | |||
"select_data": { | |||
"type": "array", | |||
"items": { | |||
"$ref": "#/definitions/md.CloudBundleVersionMap" | |||
} | |||
}, | |||
"total": { | |||
"type": "integer" | |||
} | |||
@@ -7710,6 +7754,17 @@ const docTemplate = `{ | |||
} | |||
} | |||
}, | |||
"md.CloudBundleVersionMap": { | |||
"type": "object", | |||
"properties": { | |||
"name": { | |||
"type": "string" | |||
}, | |||
"type": { | |||
"type": "string" | |||
} | |||
} | |||
}, | |||
"md.CloudBundleVersionResp": { | |||
"type": "object", | |||
"properties": { | |||
@@ -12187,12 +12242,15 @@ const docTemplate = `{ | |||
"type": "object", | |||
"properties": { | |||
"duration": { | |||
"description": "周期 (0.天 1.小时 2.周 3.月 4.年)", | |||
"description": "周期 (1.天 2.周 3.月)", | |||
"type": "integer" | |||
}, | |||
"num": { | |||
"description": "周期数", | |||
"type": "integer" | |||
"type": "array", | |||
"items": { | |||
"type": "string" | |||
} | |||
} | |||
} | |||
}, | |||
@@ -12275,32 +12333,6 @@ const docTemplate = `{ | |||
} | |||
} | |||
}, | |||
"model.PlatformTotalData": { | |||
"type": "object", | |||
"properties": { | |||
"id": { | |||
"type": "integer" | |||
}, | |||
"month": { | |||
"type": "string" | |||
}, | |||
"no_sigin_in_user_count": { | |||
"type": "integer" | |||
}, | |||
"total_user_count": { | |||
"type": "integer" | |||
}, | |||
"total_withdraw_amount": { | |||
"type": "string" | |||
}, | |||
"verified_user_count": { | |||
"type": "integer" | |||
}, | |||
"year": { | |||
"type": "string" | |||
} | |||
} | |||
}, | |||
"model.UserLevelTask": { | |||
"type": "object", | |||
"properties": { | |||
@@ -1618,7 +1618,7 @@ | |||
"200": { | |||
"description": "具体数据", | |||
"schema": { | |||
"$ref": "#/definitions/model.PlatformTotalData" | |||
"$ref": "#/definitions/hdl.TotalDataResp" | |||
} | |||
}, | |||
"400": { | |||
@@ -6644,6 +6644,35 @@ | |||
} | |||
} | |||
}, | |||
"hdl.TotalDataResp": { | |||
"type": "object", | |||
"properties": { | |||
"month": { | |||
"description": "月份", | |||
"type": "string" | |||
}, | |||
"no_sign_in_user_count": { | |||
"description": "未签到用户数", | |||
"type": "integer" | |||
}, | |||
"total_user_count": { | |||
"description": "平台总用户数", | |||
"type": "integer" | |||
}, | |||
"total_withdraw_amount": { | |||
"description": "已提现累计金额", | |||
"type": "string" | |||
}, | |||
"verified_user_count": { | |||
"description": "已认证用户数", | |||
"type": "integer" | |||
}, | |||
"year": { | |||
"description": "年份", | |||
"type": "string" | |||
} | |||
} | |||
}, | |||
"md.ActivePointsWalletNode": { | |||
"type": "object", | |||
"properties": { | |||
@@ -7601,6 +7630,9 @@ | |||
"os": { | |||
"type": "string" | |||
}, | |||
"platform": { | |||
"type": "string" | |||
}, | |||
"src": { | |||
"type": "string" | |||
}, | |||
@@ -7637,6 +7669,12 @@ | |||
"last_is_combine": { | |||
"type": "string" | |||
}, | |||
"last_platform": { | |||
"type": "array", | |||
"items": { | |||
"type": "string" | |||
} | |||
}, | |||
"list": { | |||
"type": "array", | |||
"items": { | |||
@@ -7646,6 +7684,12 @@ | |||
"list_ios": { | |||
"type": "string" | |||
}, | |||
"select_data": { | |||
"type": "array", | |||
"items": { | |||
"$ref": "#/definitions/md.CloudBundleVersionMap" | |||
} | |||
}, | |||
"total": { | |||
"type": "integer" | |||
} | |||
@@ -7703,6 +7747,17 @@ | |||
} | |||
} | |||
}, | |||
"md.CloudBundleVersionMap": { | |||
"type": "object", | |||
"properties": { | |||
"name": { | |||
"type": "string" | |||
}, | |||
"type": { | |||
"type": "string" | |||
} | |||
} | |||
}, | |||
"md.CloudBundleVersionResp": { | |||
"type": "object", | |||
"properties": { | |||
@@ -12180,12 +12235,15 @@ | |||
"type": "object", | |||
"properties": { | |||
"duration": { | |||
"description": "周期 (0.天 1.小时 2.周 3.月 4.年)", | |||
"description": "周期 (1.天 2.周 3.月)", | |||
"type": "integer" | |||
}, | |||
"num": { | |||
"description": "周期数", | |||
"type": "integer" | |||
"type": "array", | |||
"items": { | |||
"type": "string" | |||
} | |||
} | |||
} | |||
}, | |||
@@ -12268,32 +12326,6 @@ | |||
} | |||
} | |||
}, | |||
"model.PlatformTotalData": { | |||
"type": "object", | |||
"properties": { | |||
"id": { | |||
"type": "integer" | |||
}, | |||
"month": { | |||
"type": "string" | |||
}, | |||
"no_sigin_in_user_count": { | |||
"type": "integer" | |||
}, | |||
"total_user_count": { | |||
"type": "integer" | |||
}, | |||
"total_withdraw_amount": { | |||
"type": "string" | |||
}, | |||
"verified_user_count": { | |||
"type": "integer" | |||
}, | |||
"year": { | |||
"type": "string" | |||
} | |||
} | |||
}, | |||
"model.UserLevelTask": { | |||
"type": "object", | |||
"properties": { | |||
@@ -217,6 +217,27 @@ definitions: | |||
- $ref: '#/definitions/model.PlatformActiveData' | |||
description: 昨日数据 | |||
type: object | |||
hdl.TotalDataResp: | |||
properties: | |||
month: | |||
description: 月份 | |||
type: string | |||
no_sign_in_user_count: | |||
description: 未签到用户数 | |||
type: integer | |||
total_user_count: | |||
description: 平台总用户数 | |||
type: integer | |||
total_withdraw_amount: | |||
description: 已提现累计金额 | |||
type: string | |||
verified_user_count: | |||
description: 已认证用户数 | |||
type: integer | |||
year: | |||
description: 年份 | |||
type: string | |||
type: object | |||
md.ActivePointsWalletNode: | |||
properties: | |||
amount: | |||
@@ -878,6 +899,8 @@ definitions: | |||
type: string | |||
os: | |||
type: string | |||
platform: | |||
type: string | |||
src: | |||
type: string | |||
state: | |||
@@ -902,12 +925,20 @@ definitions: | |||
type: string | |||
last_is_combine: | |||
type: string | |||
last_platform: | |||
items: | |||
type: string | |||
type: array | |||
list: | |||
items: | |||
$ref: '#/definitions/md.CloudBundleList' | |||
type: array | |||
list_ios: | |||
type: string | |||
select_data: | |||
items: | |||
$ref: '#/definitions/md.CloudBundleVersionMap' | |||
type: array | |||
total: | |||
type: integer | |||
type: object | |||
@@ -945,6 +976,13 @@ definitions: | |||
version: | |||
type: string | |||
type: object | |||
md.CloudBundleVersionMap: | |||
properties: | |||
name: | |||
type: string | |||
type: | |||
type: string | |||
type: object | |||
md.CloudBundleVersionResp: | |||
properties: | |||
version: | |||
@@ -4072,11 +4110,13 @@ definitions: | |||
md.WithdrawFrequencySettingStruct: | |||
properties: | |||
duration: | |||
description: 周期 (0.天 1.小时 2.周 3.月 4.年) | |||
description: 周期 (1.天 2.周 3.月) | |||
type: integer | |||
num: | |||
description: 周期数 | |||
type: integer | |||
items: | |||
type: string | |||
type: array | |||
type: object | |||
model.EggEnergyUserEggIndexWeight: | |||
properties: | |||
@@ -4130,23 +4170,6 @@ definitions: | |||
withdraw_user_count: | |||
type: integer | |||
type: object | |||
model.PlatformTotalData: | |||
properties: | |||
id: | |||
type: integer | |||
month: | |||
type: string | |||
no_sigin_in_user_count: | |||
type: integer | |||
total_user_count: | |||
type: integer | |||
total_withdraw_amount: | |||
type: string | |||
verified_user_count: | |||
type: integer | |||
year: | |||
type: string | |||
type: object | |||
model.UserLevelTask: | |||
properties: | |||
create_at: | |||
@@ -5238,7 +5261,7 @@ paths: | |||
"200": | |||
description: 具体数据 | |||
schema: | |||
$ref: '#/definitions/model.PlatformTotalData' | |||
$ref: '#/definitions/hdl.TotalDataResp' | |||
"400": | |||
description: 具体错误 | |||
schema: | |||
@@ -33,8 +33,8 @@ require ( | |||
) | |||
require ( | |||
code.fnuoos.com/EggPlanet/egg_models.git v0.2.1-0.20241128084936-6c2fce34f497 | |||
code.fnuoos.com/EggPlanet/egg_system_rules.git v0.0.4-0.20241128091751-2e1e6fbe16c7 | |||
code.fnuoos.com/EggPlanet/egg_models.git v0.2.1-0.20241128093644-212e906d846c | |||
code.fnuoos.com/EggPlanet/egg_system_rules.git v0.0.4-0.20241128093118-1efc428b8a55 | |||
code.fnuoos.com/go_rely_warehouse/zyos_go_es.git v1.0.1-0.20241118083738-0f22da9ba0be | |||
code.fnuoos.com/go_rely_warehouse/zyos_go_mq.git v0.0.5 | |||
github.com/360EntSecGroup-Skylar/excelize v1.4.1 | |||