1、新增自定义用户私人价格2、优化api服务鉴权缓存3、新增管理员端对公充值

This commit is contained in:
2024-10-21 16:01:20 +08:00
parent 8896fd6b30
commit 2292d25d74
37 changed files with 1903 additions and 907 deletions

View File

@@ -152,3 +152,41 @@ service admin-api {
get /list (GetProductListReq) returns (GetProductListResp)
}
type (
UserListRequest {
Page int64 `json:"page"` // 分页页码
PageSize int64 `json:"pageSize"` // 每页大小
}
UserListResponse {
List []UserItem `json:"list"`
Total int64 `json:"total"`
}
UserItem {
Id int64 `json:"id"` // 主键ID
Username string `json:"username"` // 用户名
Phone string `json:"phone"` // 电话
Disable int64 `json:"disable"` // 是否禁用状态1为禁用0为启用
QuotaExceeded int64 `json:"quotaExceeded"` // 是否超出配额1为超出0为未超出
Balance float64 `json:"balance"` // 余额
CreatedAt string `json:"createdAt"` // 创建时间
UpdatedAt string `json:"updatedAt"` // 更新时间
}
rechargeRequest {
UserId int64 `json:userId`
Amount int64 `json:amount`
}
)
@server (
group: user
prefix: /api/admin/user
middleware: AuthInterceptor
)
service admin-api {
@handler getUserList
post /user/list (UserListRequest) returns (UserListResponse)
@handler recharge
post /user/recharge (rechargeRequest)
}