Browse Source

update

herolist
dengbiao 3 weeks ago
parent
commit
0fefb11a88
1 changed files with 26 additions and 26 deletions
  1. +26
    -26
      app/svc/svc_withdraw_apply.go

+ 26
- 26
app/svc/svc_withdraw_apply.go View File

@@ -200,32 +200,6 @@ func GetWithdrawCondition(user *model.User, setting *model.FinWithdrawSetting, i
}(firstWithdrawSet.IsNeedRealName)
resp.FirstWithdrawAmountLimit = firstWithdrawSet.FirstWithdrawAmountLimit
} else {
// 2.判断是否需要实名
switch setting.IsRealName {
case 0:
resp.IsNeedRealName = false
case 1:
resp.IsNeedRealName = true
default:
resp.IsNeedRealName = true
}

// 3.判断是否实名
switch user.IsRealName {
case 0:
resp.IsRealName = false
if resp.IsNeedRealName {
// 2.1 需要实名但未实名
resp.IsCanWithdraw = false
resp.NotWithdrawReason = enum.FinWithdrawApplyWithdrawConditionDissatisfyKind.
String(enum.FinWithdrawApplyWithdrawConditionDissatisfyKindNotRealName)
}
case 1:
resp.IsRealName = true
default:
resp.IsRealName = false
}

// 4. 验证会员等级
if setting.VipLevelLimit > 0 && setting.VipLevelLimit > user.Level {
resp.IsCanWithdraw = false
@@ -281,6 +255,32 @@ func GetWithdrawCondition(user *model.User, setting *model.FinWithdrawSetting, i
}
}

// 2.判断是否需要实名
switch setting.IsRealName {
case 0:
resp.IsNeedRealName = false
case 1:
resp.IsNeedRealName = true
default:
resp.IsNeedRealName = true
}

// 3.判断是否实名
switch user.IsRealName {
case 0:
resp.IsRealName = false
if resp.IsNeedRealName {
// 2.1 需要实名但未实名
resp.IsCanWithdraw = false
resp.NotWithdrawReason = enum.FinWithdrawApplyWithdrawConditionDissatisfyKind.
String(enum.FinWithdrawApplyWithdrawConditionDissatisfyKindNotRealName)
}
case 1:
resp.IsRealName = true
default:
resp.IsRealName = false
}

//6、验证时段
if setting.WithdrawTimeInterval != "" {
withdrawTimeInterval := strings.Split(setting.WithdrawTimeInterval, "-")


Loading…
Cancel
Save