fix: 统一管理员认证列表的分页参数为 offset/limit

This commit is contained in:
zetaloop
2026-04-07 17:14:20 +08:00
parent 65787c6583
commit 424b2b1cca
4 changed files with 14 additions and 15 deletions
@@ -36,16 +36,16 @@ func (l *GetVerificationsLogic) GetVerifications(req *types.GetPendingListReq) (
if err != nil {
return nil, err
}
page := req.Page
if page < 1 {
page = 1
offset := req.Offset
if offset < 0 {
offset = 0
}
limit := req.Size
limit := req.Limit
if limit <= 0 {
limit = 20
}
verifications, err := l.svcCtx.UserVerificationsRpc.SearchUserVerifications(l.ctx, &pb.SearchUserVerificationsReq{
Page: page - 1,
Page: offset / limit,
Limit: limit,
Role: req.Role,
Status: req.Status,