feat: add super admin health review
This commit is contained in:
@@ -294,6 +294,43 @@ type TenantItem struct {
|
||||
Users []*SuperUserLite `json:"users"`
|
||||
}
|
||||
|
||||
type TenantHealthItem struct {
|
||||
// TenantID 租户ID。
|
||||
TenantID int64 `json:"tenant_id"`
|
||||
// Code 租户编码。
|
||||
Code string `json:"code"`
|
||||
// Name 租户名称。
|
||||
Name string `json:"name"`
|
||||
// Status 租户状态。
|
||||
Status consts.TenantStatus `json:"status"`
|
||||
// StatusDescription 租户状态描述(用于展示)。
|
||||
StatusDescription string `json:"status_description"`
|
||||
// Owner 租户所有者信息。
|
||||
Owner *TenantOwnerUserLite `json:"owner"`
|
||||
// MemberCount 租户成员数量(包含管理员)。
|
||||
MemberCount int64 `json:"member_count"`
|
||||
// ContentCount 内容总数。
|
||||
ContentCount int64 `json:"content_count"`
|
||||
// PublishedContentCount 已发布内容数量。
|
||||
PublishedContentCount int64 `json:"published_content_count"`
|
||||
// PaidOrders 已支付订单数(内容购买)。
|
||||
PaidOrders int64 `json:"paid_orders"`
|
||||
// PaidAmount 已支付金额(分)。
|
||||
PaidAmount int64 `json:"paid_amount"`
|
||||
// RefundOrders 已退款订单数(内容购买)。
|
||||
RefundOrders int64 `json:"refund_orders"`
|
||||
// RefundAmount 已退款金额(分)。
|
||||
RefundAmount int64 `json:"refund_amount"`
|
||||
// RefundRate 退款率(退款订单数 / 已支付订单数)。
|
||||
RefundRate float64 `json:"refund_rate"`
|
||||
// LastPaidAt 最近成交时间(RFC3339,空代表暂无成交)。
|
||||
LastPaidAt string `json:"last_paid_at"`
|
||||
// HealthLevel 健康等级(healthy/warning/risk)。
|
||||
HealthLevel string `json:"health_level"`
|
||||
// Alerts 异常提示列表(用于运营侧提示)。
|
||||
Alerts []string `json:"alerts"`
|
||||
}
|
||||
|
||||
type TenantOwnerUserLite struct {
|
||||
// ID 用户ID。
|
||||
ID int64 `json:"id"`
|
||||
@@ -347,6 +384,13 @@ type SuperTenantContentStatusUpdateForm struct {
|
||||
Status consts.ContentStatus `json:"status" validate:"required,oneof=unpublished blocked"`
|
||||
}
|
||||
|
||||
type SuperContentReviewForm struct {
|
||||
// Action 审核动作(approve/reject)。
|
||||
Action string `json:"action" validate:"required,oneof=approve reject"`
|
||||
// Reason 审核说明(驳回时填写,便于作者修正)。
|
||||
Reason string `json:"reason"`
|
||||
}
|
||||
|
||||
type SuperTenantUserItem struct {
|
||||
// User 用户信息。
|
||||
User *SuperUserLite `json:"user"`
|
||||
|
||||
Reference in New Issue
Block a user