Initial commit

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
2026-09-15 13:57:10 +08:00
co-authored by Claude Opus 5
commit 8679200f41
1897 changed files with 257900 additions and 0 deletions
+40
View File
@@ -0,0 +1,40 @@
package backpack_ctrl
import (
"91porn-server/common"
"91porn-server/common/log"
"91porn-server/common/stderr"
"91porn-server/models/v/backpackmod"
"91porn-server/web/service/backpack_service"
"fmt"
"github.com/gin-gonic/gin"
)
// QueryAll doc
// @Summary 查询用户背包
// @Description 查询用户背包
// @Tags 用户
// @Accept mpfd,json
// @Produce json,html
// @Param Uid query int false "搜索用户ID"
// @Param page query int64 true "第几页"
// @Param limit query int64 true "每页数量"
// @Success 200 object backpackmod.QueryAllRes "成功后返回"
// @Failure 400 {string} json "{"msg": "操作失败"}"
// @Router /api/web/admin/backpack [get]
func QueryAll(c *gin.Context) {
var in backpackmod.QueryAllWebCond
if err := c.ShouldBindQuery(&in); err != nil {
log.Error(fmt.Sprintf("Query all backpack param err%v\n", err))
common.ServeJSON(c, stderr.ErrParamError, nil)
return
}
data, err := backpack_service.QueryAll(&in)
if err != nil {
log.Error(fmt.Sprintf("Query all backpack err%v\n%d", data, err))
common.ServeJSON(c, stderr.Failure, nil)
return
}
common.ServeJSON(c, stderr.Success, data)
}