支持客服主动发起申诉

This commit is contained in:
yml2213
2026-07-26 09:54:27 +08:00
parent 4bc25b87d8
commit 9ccc16e068
20 changed files with 522 additions and 25 deletions
@@ -129,6 +129,29 @@ func (h *Handler) AdminList(c *gin.Context) {
response.OK(c, result)
}
func (h *Handler) AdminCreateByOrder(c *gin.Context) {
adminID, ok := currentAdminID(c)
if !ok {
response.Unauthorized(c, "缺少管理员上下文")
return
}
orderID, ok := parseID(c)
if !ok {
return
}
var req AdminCreateRequest
if err := c.ShouldBindJSON(&req); err != nil {
response.BadRequest(c, "申诉信息不完整")
return
}
item, err := h.service.AdminCreateByOrder(c.Request.Context(), adminID, orderID, req, auditMeta(c))
if err != nil {
writeDisputeError(c, err)
return
}
response.Created(c, item)
}
func (h *Handler) AdminArbitrate(c *gin.Context) {
adminID, ok := currentAdminID(c)
if !ok {