feat: add super comment governance and finance oversight
This commit is contained in:
@@ -247,6 +247,99 @@ const docTemplate = `{
|
||||
}
|
||||
}
|
||||
},
|
||||
"/super/v1/comments": {
|
||||
"get": {
|
||||
"description": "List comments across tenants",
|
||||
"consumes": [
|
||||
"application/json"
|
||||
],
|
||||
"produces": [
|
||||
"application/json"
|
||||
],
|
||||
"tags": [
|
||||
"Content"
|
||||
],
|
||||
"summary": "List comments",
|
||||
"parameters": [
|
||||
{
|
||||
"type": "integer",
|
||||
"description": "Page number",
|
||||
"name": "page",
|
||||
"in": "query"
|
||||
},
|
||||
{
|
||||
"type": "integer",
|
||||
"description": "Page size",
|
||||
"name": "limit",
|
||||
"in": "query"
|
||||
}
|
||||
],
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "OK",
|
||||
"schema": {
|
||||
"allOf": [
|
||||
{
|
||||
"$ref": "#/definitions/requests.Pager"
|
||||
},
|
||||
{
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"items": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"$ref": "#/definitions/dto.SuperCommentItem"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"/super/v1/comments/{id}/delete": {
|
||||
"post": {
|
||||
"description": "Soft delete a comment",
|
||||
"consumes": [
|
||||
"application/json"
|
||||
],
|
||||
"produces": [
|
||||
"application/json"
|
||||
],
|
||||
"tags": [
|
||||
"Content"
|
||||
],
|
||||
"summary": "Delete comment",
|
||||
"parameters": [
|
||||
{
|
||||
"type": "integer",
|
||||
"format": "int64",
|
||||
"description": "Comment ID",
|
||||
"name": "id",
|
||||
"in": "path",
|
||||
"required": true
|
||||
},
|
||||
{
|
||||
"description": "Delete form",
|
||||
"name": "form",
|
||||
"in": "body",
|
||||
"schema": {
|
||||
"$ref": "#/definitions/dto.SuperCommentDeleteForm"
|
||||
}
|
||||
}
|
||||
],
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "Deleted",
|
||||
"schema": {
|
||||
"type": "string"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"/super/v1/contents": {
|
||||
"get": {
|
||||
"description": "List contents",
|
||||
@@ -742,6 +835,162 @@ const docTemplate = `{
|
||||
}
|
||||
}
|
||||
},
|
||||
"/super/v1/finance/anomalies/balances": {
|
||||
"get": {
|
||||
"description": "List balance anomalies across users",
|
||||
"consumes": [
|
||||
"application/json"
|
||||
],
|
||||
"produces": [
|
||||
"application/json"
|
||||
],
|
||||
"tags": [
|
||||
"Finance"
|
||||
],
|
||||
"summary": "List balance anomalies",
|
||||
"parameters": [
|
||||
{
|
||||
"type": "integer",
|
||||
"description": "Page number",
|
||||
"name": "page",
|
||||
"in": "query"
|
||||
},
|
||||
{
|
||||
"type": "integer",
|
||||
"description": "Page size",
|
||||
"name": "limit",
|
||||
"in": "query"
|
||||
}
|
||||
],
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "OK",
|
||||
"schema": {
|
||||
"allOf": [
|
||||
{
|
||||
"$ref": "#/definitions/requests.Pager"
|
||||
},
|
||||
{
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"items": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"$ref": "#/definitions/dto.SuperBalanceAnomalyItem"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"/super/v1/finance/anomalies/orders": {
|
||||
"get": {
|
||||
"description": "List order anomalies across tenants",
|
||||
"consumes": [
|
||||
"application/json"
|
||||
],
|
||||
"produces": [
|
||||
"application/json"
|
||||
],
|
||||
"tags": [
|
||||
"Finance"
|
||||
],
|
||||
"summary": "List order anomalies",
|
||||
"parameters": [
|
||||
{
|
||||
"type": "integer",
|
||||
"description": "Page number",
|
||||
"name": "page",
|
||||
"in": "query"
|
||||
},
|
||||
{
|
||||
"type": "integer",
|
||||
"description": "Page size",
|
||||
"name": "limit",
|
||||
"in": "query"
|
||||
}
|
||||
],
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "OK",
|
||||
"schema": {
|
||||
"allOf": [
|
||||
{
|
||||
"$ref": "#/definitions/requests.Pager"
|
||||
},
|
||||
{
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"items": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"$ref": "#/definitions/dto.SuperOrderAnomalyItem"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"/super/v1/finance/ledgers": {
|
||||
"get": {
|
||||
"description": "List tenant ledgers across tenants",
|
||||
"consumes": [
|
||||
"application/json"
|
||||
],
|
||||
"produces": [
|
||||
"application/json"
|
||||
],
|
||||
"tags": [
|
||||
"Finance"
|
||||
],
|
||||
"summary": "List ledgers",
|
||||
"parameters": [
|
||||
{
|
||||
"type": "integer",
|
||||
"description": "Page number",
|
||||
"name": "page",
|
||||
"in": "query"
|
||||
},
|
||||
{
|
||||
"type": "integer",
|
||||
"description": "Page size",
|
||||
"name": "limit",
|
||||
"in": "query"
|
||||
}
|
||||
],
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "OK",
|
||||
"schema": {
|
||||
"allOf": [
|
||||
{
|
||||
"$ref": "#/definitions/requests.Pager"
|
||||
},
|
||||
{
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"items": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"$ref": "#/definitions/dto.SuperLedgerItem"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"/super/v1/notifications": {
|
||||
"get": {
|
||||
"description": "List notifications across tenants",
|
||||
@@ -5830,6 +6079,25 @@ const docTemplate = `{
|
||||
"RoleCreator"
|
||||
]
|
||||
},
|
||||
"consts.TenantLedgerType": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"debit_purchase",
|
||||
"credit_refund",
|
||||
"credit_withdrawal",
|
||||
"freeze",
|
||||
"unfreeze",
|
||||
"adjustment"
|
||||
],
|
||||
"x-enum-varnames": [
|
||||
"TenantLedgerTypeDebitPurchase",
|
||||
"TenantLedgerTypeCreditRefund",
|
||||
"TenantLedgerTypeCreditWithdrawal",
|
||||
"TenantLedgerTypeFreeze",
|
||||
"TenantLedgerTypeUnfreeze",
|
||||
"TenantLedgerTypeAdjustment"
|
||||
]
|
||||
},
|
||||
"consts.TenantStatus": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
@@ -7435,6 +7703,109 @@ const docTemplate = `{
|
||||
}
|
||||
}
|
||||
},
|
||||
"dto.SuperBalanceAnomalyItem": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"balance": {
|
||||
"description": "Balance 可用余额(分)。",
|
||||
"type": "integer"
|
||||
},
|
||||
"balance_frozen": {
|
||||
"description": "BalanceFrozen 冻结余额(分)。",
|
||||
"type": "integer"
|
||||
},
|
||||
"created_at": {
|
||||
"description": "CreatedAt 用户创建时间(RFC3339)。",
|
||||
"type": "string"
|
||||
},
|
||||
"issue": {
|
||||
"description": "Issue 异常类型标识。",
|
||||
"type": "string"
|
||||
},
|
||||
"issue_description": {
|
||||
"description": "IssueDescription 异常描述说明。",
|
||||
"type": "string"
|
||||
},
|
||||
"user_id": {
|
||||
"description": "UserID 用户ID。",
|
||||
"type": "integer"
|
||||
},
|
||||
"username": {
|
||||
"description": "Username 用户名。",
|
||||
"type": "string"
|
||||
}
|
||||
}
|
||||
},
|
||||
"dto.SuperCommentDeleteForm": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"reason": {
|
||||
"description": "Reason 删除原因(可选,用于审计记录)。",
|
||||
"type": "string"
|
||||
}
|
||||
}
|
||||
},
|
||||
"dto.SuperCommentItem": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"content": {
|
||||
"description": "Content 评论内容。",
|
||||
"type": "string"
|
||||
},
|
||||
"content_id": {
|
||||
"description": "ContentID 内容ID。",
|
||||
"type": "integer"
|
||||
},
|
||||
"content_title": {
|
||||
"description": "ContentTitle 内容标题。",
|
||||
"type": "string"
|
||||
},
|
||||
"created_at": {
|
||||
"description": "CreatedAt 创建时间(RFC3339)。",
|
||||
"type": "string"
|
||||
},
|
||||
"deleted_at": {
|
||||
"description": "DeletedAt 删除时间(RFC3339,未删除为空)。",
|
||||
"type": "string"
|
||||
},
|
||||
"id": {
|
||||
"description": "ID 评论ID。",
|
||||
"type": "integer"
|
||||
},
|
||||
"is_deleted": {
|
||||
"description": "IsDeleted 是否已删除。",
|
||||
"type": "boolean"
|
||||
},
|
||||
"likes": {
|
||||
"description": "Likes 评论点赞数。",
|
||||
"type": "integer"
|
||||
},
|
||||
"reply_to": {
|
||||
"description": "ReplyTo 回复评论ID(0 表示一级评论)。",
|
||||
"type": "integer"
|
||||
},
|
||||
"tenant_code": {
|
||||
"description": "TenantCode 租户编码。",
|
||||
"type": "string"
|
||||
},
|
||||
"tenant_id": {
|
||||
"description": "TenantID 租户ID。",
|
||||
"type": "integer"
|
||||
},
|
||||
"tenant_name": {
|
||||
"description": "TenantName 租户名称。",
|
||||
"type": "string"
|
||||
},
|
||||
"user_id": {
|
||||
"description": "UserID 评论用户ID。",
|
||||
"type": "integer"
|
||||
},
|
||||
"username": {
|
||||
"description": "Username 评论用户名称。",
|
||||
"type": "string"
|
||||
}
|
||||
}
|
||||
},
|
||||
"dto.SuperContentBatchReviewForm": {
|
||||
"type": "object",
|
||||
"required": [
|
||||
@@ -7809,6 +8180,95 @@ const docTemplate = `{
|
||||
}
|
||||
}
|
||||
},
|
||||
"dto.SuperLedgerItem": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"amount": {
|
||||
"description": "Amount 变动金额(分)。",
|
||||
"type": "integer"
|
||||
},
|
||||
"balance_after": {
|
||||
"description": "BalanceAfter 变更后可用余额(分)。",
|
||||
"type": "integer"
|
||||
},
|
||||
"balance_before": {
|
||||
"description": "BalanceBefore 变更前可用余额(分)。",
|
||||
"type": "integer"
|
||||
},
|
||||
"biz_ref_id": {
|
||||
"description": "BizRefID 业务引用ID(可选)。",
|
||||
"type": "integer"
|
||||
},
|
||||
"biz_ref_type": {
|
||||
"description": "BizRefType 业务引用类型(可选)。",
|
||||
"type": "string"
|
||||
},
|
||||
"created_at": {
|
||||
"description": "CreatedAt 创建时间(RFC3339)。",
|
||||
"type": "string"
|
||||
},
|
||||
"frozen_after": {
|
||||
"description": "FrozenAfter 变更后冻结余额(分)。",
|
||||
"type": "integer"
|
||||
},
|
||||
"frozen_before": {
|
||||
"description": "FrozenBefore 变更前冻结余额(分)。",
|
||||
"type": "integer"
|
||||
},
|
||||
"id": {
|
||||
"description": "ID 流水ID。",
|
||||
"type": "integer"
|
||||
},
|
||||
"operator_user_id": {
|
||||
"description": "OperatorUserID 操作者用户ID(0 表示系统)。",
|
||||
"type": "integer"
|
||||
},
|
||||
"order_id": {
|
||||
"description": "OrderID 关联订单ID。",
|
||||
"type": "integer"
|
||||
},
|
||||
"remark": {
|
||||
"description": "Remark 流水备注说明。",
|
||||
"type": "string"
|
||||
},
|
||||
"tenant_code": {
|
||||
"description": "TenantCode 租户编码。",
|
||||
"type": "string"
|
||||
},
|
||||
"tenant_id": {
|
||||
"description": "TenantID 租户ID。",
|
||||
"type": "integer"
|
||||
},
|
||||
"tenant_name": {
|
||||
"description": "TenantName 租户名称。",
|
||||
"type": "string"
|
||||
},
|
||||
"type": {
|
||||
"description": "Type 流水类型。",
|
||||
"allOf": [
|
||||
{
|
||||
"$ref": "#/definitions/consts.TenantLedgerType"
|
||||
}
|
||||
]
|
||||
},
|
||||
"type_description": {
|
||||
"description": "TypeDescription 流水类型描述(用于展示)。",
|
||||
"type": "string"
|
||||
},
|
||||
"updated_at": {
|
||||
"description": "UpdatedAt 更新时间(RFC3339)。",
|
||||
"type": "string"
|
||||
},
|
||||
"user_id": {
|
||||
"description": "UserID 关联用户ID。",
|
||||
"type": "integer"
|
||||
},
|
||||
"username": {
|
||||
"description": "Username 关联用户名。",
|
||||
"type": "string"
|
||||
}
|
||||
}
|
||||
},
|
||||
"dto.SuperNotificationBroadcastForm": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
@@ -7980,6 +8440,75 @@ const docTemplate = `{
|
||||
}
|
||||
}
|
||||
},
|
||||
"dto.SuperOrderAnomalyItem": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"amount_paid": {
|
||||
"description": "AmountPaid 实付金额(分)。",
|
||||
"type": "integer"
|
||||
},
|
||||
"created_at": {
|
||||
"description": "CreatedAt 创建时间(RFC3339)。",
|
||||
"type": "string"
|
||||
},
|
||||
"issue": {
|
||||
"description": "Issue 异常类型标识。",
|
||||
"type": "string"
|
||||
},
|
||||
"issue_description": {
|
||||
"description": "IssueDescription 异常描述说明。",
|
||||
"type": "string"
|
||||
},
|
||||
"order_id": {
|
||||
"description": "OrderID 订单ID。",
|
||||
"type": "integer"
|
||||
},
|
||||
"paid_at": {
|
||||
"description": "PaidAt 支付时间(RFC3339)。",
|
||||
"type": "string"
|
||||
},
|
||||
"refunded_at": {
|
||||
"description": "RefundedAt 退款时间(RFC3339)。",
|
||||
"type": "string"
|
||||
},
|
||||
"status": {
|
||||
"description": "Status 订单状态。",
|
||||
"allOf": [
|
||||
{
|
||||
"$ref": "#/definitions/consts.OrderStatus"
|
||||
}
|
||||
]
|
||||
},
|
||||
"tenant_code": {
|
||||
"description": "TenantCode 租户编码。",
|
||||
"type": "string"
|
||||
},
|
||||
"tenant_id": {
|
||||
"description": "TenantID 租户ID。",
|
||||
"type": "integer"
|
||||
},
|
||||
"tenant_name": {
|
||||
"description": "TenantName 租户名称。",
|
||||
"type": "string"
|
||||
},
|
||||
"type": {
|
||||
"description": "Type 订单类型。",
|
||||
"allOf": [
|
||||
{
|
||||
"$ref": "#/definitions/consts.OrderType"
|
||||
}
|
||||
]
|
||||
},
|
||||
"user_id": {
|
||||
"description": "UserID 用户ID。",
|
||||
"type": "integer"
|
||||
},
|
||||
"username": {
|
||||
"description": "Username 用户名。",
|
||||
"type": "string"
|
||||
}
|
||||
}
|
||||
},
|
||||
"dto.SuperOrderDetail": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
|
||||
Reference in New Issue
Block a user