feat: 接入旧站管理端并完整迁移后台能力

This commit is contained in:
yml
2026-11-12 22:03:01 +08:00
parent e5f923706b
commit a4441bba9a
509 changed files with 140714 additions and 1068 deletions
@@ -112,6 +112,22 @@ func (h *Handler) StartMohong(c *gin.Context) {
response.OK(c, item)
}
func (h *Handler) StartQualityOwner(c *gin.Context) {
userID, ok := currentUserID(c)
if !ok {
response.Unauthorized(c, "缺少用户上下文")
return
}
var req StartPaymentRequest
_ = c.ShouldBindJSON(&req)
item, err := h.service.StartQualityOwner(c.Request.Context(), userID, req, c.ClientIP())
if err != nil {
writePaymentError(c, err)
return
}
response.OK(c, item)
}
func (h *Handler) Query(c *gin.Context) {
userID, ok := currentUserID(c)
if !ok {
@@ -148,6 +164,20 @@ func (h *Handler) QueryMohong(c *gin.Context) {
response.OK(c, item)
}
func (h *Handler) QueryQualityOwner(c *gin.Context) {
userID, ok := currentUserID(c)
if !ok {
response.Unauthorized(c, "缺少用户上下文")
return
}
item, err := h.service.QueryQualityOwner(c.Request.Context(), userID)
if err != nil {
writePaymentError(c, err)
return
}
response.OK(c, item)
}
func (h *Handler) AdminRefundMohong(c *gin.Context) {
orderID, ok := parseID(c)
if !ok {