Merge pull request 'feat-IRONFANS-70' (#332) from feat-IRONFANS-70 into test

Reviewed-on: http://121.41.31.146:3000/wishpal_ironfan/service/pulls/332
This commit is contained in:
chenhao 2024-04-25 16:41:12 +08:00
commit bf783ceb8b
1 changed files with 5 additions and 0 deletions

View File

@ -402,6 +402,11 @@ func (l *AuthBusinessValidator) EnsureAccountPunishmentHasNotTerminated(id int64
func (l *AuthBusinessValidator) EnsureAccountPunishmentMatchesRoleOfTarget(uid int64, typ int64, QueryFunc func(ctx *gin.Context, req *accountproto.OpListByMidReq) (*dbstruct.Account, error)) *AuthBusinessValidator { func (l *AuthBusinessValidator) EnsureAccountPunishmentMatchesRoleOfTarget(uid int64, typ int64, QueryFunc func(ctx *gin.Context, req *accountproto.OpListByMidReq) (*dbstruct.Account, error)) *AuthBusinessValidator {
l.oplist = append(l.oplist, func() { l.oplist = append(l.oplist, func() {
if len(consts.AccountPunishmentRoleMap[typ]) == 0 {
return
}
acct, err := QueryFunc(l.ctx, &accountproto.OpListByMidReq{ acct, err := QueryFunc(l.ctx, &accountproto.OpListByMidReq{
Mid: goproto.Int64(uid), Mid: goproto.Int64(uid),
}) })