feat: 修复必传数据解析错误问题
This commit is contained in:
@@ -42,7 +42,7 @@ func ParseValidateRule(dataType reflect.Type, ruleStr string) ValidateRule {
|
|||||||
if len(itemRule) == 0 {
|
if len(itemRule) == 0 {
|
||||||
continue
|
continue
|
||||||
}
|
}
|
||||||
if strings.Contains(itemRule, "=") {
|
if !strings.Contains(itemRule, "=") {
|
||||||
// 一定是无需要值的验证规则
|
// 一定是无需要值的验证规则
|
||||||
switch itemRule {
|
switch itemRule {
|
||||||
case consts.ValidatorRuleCommonRequired.String(): // 必传
|
case consts.ValidatorRuleCommonRequired.String(): // 必传
|
||||||
|
|||||||
Reference in New Issue
Block a user