feat: enhance superadmin dashboard overview

This commit is contained in:
2026-01-15 14:16:20 +08:00
parent a8453e0c6c
commit c683fa5cf3
10 changed files with 449 additions and 10 deletions

View File

@@ -167,6 +167,29 @@ const docTemplate = `{
}
}
},
"/super/v1/contents/statistics": {
"get": {
"description": "Content statistics",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"tags": [
"Content"
],
"summary": "Content statistics",
"responses": {
"200": {
"description": "OK",
"schema": {
"$ref": "#/definitions/dto.SuperContentStatisticsResponse"
}
}
}
}
},
"/super/v1/contents/{id}/review": {
"post": {
"description": "Review content",
@@ -6374,6 +6397,22 @@ const docTemplate = `{
}
}
},
"dto.SuperContentStatisticsResponse": {
"type": "object",
"properties": {
"total_count": {
"description": "TotalCount 内容总量。",
"type": "integer"
},
"trend": {
"description": "Trend 按天新增内容趋势。",
"type": "array",
"items": {
"$ref": "#/definitions/dto.SuperContentTrendItem"
}
}
}
},
"dto.SuperContentTenantLite": {
"type": "object",
"properties": {
@@ -6391,6 +6430,19 @@ const docTemplate = `{
}
}
},
"dto.SuperContentTrendItem": {
"type": "object",
"properties": {
"created_count": {
"description": "CreatedCount 当日新增内容数量。",
"type": "integer"
},
"date": {
"description": "Date 日期YYYY-MM-DD。",
"type": "string"
}
}
},
"dto.SuperCouponGrantItem": {
"type": "object",
"properties": {

View File

@@ -161,6 +161,29 @@
}
}
},
"/super/v1/contents/statistics": {
"get": {
"description": "Content statistics",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"tags": [
"Content"
],
"summary": "Content statistics",
"responses": {
"200": {
"description": "OK",
"schema": {
"$ref": "#/definitions/dto.SuperContentStatisticsResponse"
}
}
}
}
},
"/super/v1/contents/{id}/review": {
"post": {
"description": "Review content",
@@ -6368,6 +6391,22 @@
}
}
},
"dto.SuperContentStatisticsResponse": {
"type": "object",
"properties": {
"total_count": {
"description": "TotalCount 内容总量。",
"type": "integer"
},
"trend": {
"description": "Trend 按天新增内容趋势。",
"type": "array",
"items": {
"$ref": "#/definitions/dto.SuperContentTrendItem"
}
}
}
},
"dto.SuperContentTenantLite": {
"type": "object",
"properties": {
@@ -6385,6 +6424,19 @@
}
}
},
"dto.SuperContentTrendItem": {
"type": "object",
"properties": {
"created_count": {
"description": "CreatedCount 当日新增内容数量。",
"type": "integer"
},
"date": {
"description": "Date 日期YYYY-MM-DD。",
"type": "string"
}
}
},
"dto.SuperCouponGrantItem": {
"type": "object",
"properties": {

View File

@@ -1048,6 +1048,17 @@ definitions:
required:
- action
type: object
dto.SuperContentStatisticsResponse:
properties:
total_count:
description: TotalCount 内容总量。
type: integer
trend:
description: Trend 按天新增内容趋势。
items:
$ref: '#/definitions/dto.SuperContentTrendItem'
type: array
type: object
dto.SuperContentTenantLite:
properties:
code:
@@ -1060,6 +1071,15 @@ definitions:
description: Name 租户名称。
type: string
type: object
dto.SuperContentTrendItem:
properties:
created_count:
description: CreatedCount 当日新增内容数量。
type: integer
date:
description: Date 日期YYYY-MM-DD
type: string
type: object
dto.SuperCouponGrantItem:
properties:
coupon_id:
@@ -2500,6 +2520,21 @@ paths:
summary: Batch review contents
tags:
- Content
/super/v1/contents/statistics:
get:
consumes:
- application/json
description: Content statistics
produces:
- application/json
responses:
"200":
description: OK
schema:
$ref: '#/definitions/dto.SuperContentStatisticsResponse'
summary: Content statistics
tags:
- Content
/super/v1/coupon-grants:
get:
consumes: