diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/expert/manage/ExpertManage.java b/pmapi/src/main/java/com/ningdatech/pmapi/expert/manage/ExpertManage.java index d2f0dd9..f884ae3 100644 --- a/pmapi/src/main/java/com/ningdatech/pmapi/expert/manage/ExpertManage.java +++ b/pmapi/src/main/java/com/ningdatech/pmapi/expert/manage/ExpertManage.java @@ -44,6 +44,7 @@ import com.ningdatech.pmapi.user.util.LoginUserUtil; import lombok.RequiredArgsConstructor; import lombok.extern.slf4j.Slf4j; import org.apache.commons.collections4.CollectionUtils; +import org.springframework.beans.factory.annotation.Value; import org.springframework.http.MediaType; import org.springframework.stereotype.Component; import org.springframework.transaction.annotation.Transactional; @@ -80,6 +81,9 @@ public class ExpertManage { private final VerifyCodeCheckHelper verifyCodeCheckHelper; private final CachePlusOps cachePlusOps; + @Value("${expert-registration.verify-code.check:true}") + private Boolean expertRegistrationVerifyCodeCheck; + private static final Duration REGISTER_EXPIRED_DURATION = Duration.ofDays(3); private static final Duration REGISTER_GEN_DURATION = Duration.ofMinutes(30); @@ -225,7 +229,7 @@ public class ExpertManage { String verificationCode = request.getVerificationCode(); String phoneNo = request.getBasicInfo().getPhoneNo(); //校验 专家验证码 - if (false) { + if (expertRegistrationVerifyCodeCheck) { verifyCodeCheckHelper.verification(VerificationCodeType.EXPERT_REGISTER, phoneNo, verificationCode); } assemblerAndGenerateExpert(request, null); diff --git a/pmapi/src/main/resources/application-dev.yml b/pmapi/src/main/resources/application-dev.yml index 4c5f27b..df8b278 100644 --- a/pmapi/src/main/resources/application-dev.yml +++ b/pmapi/src/main/resources/application-dev.yml @@ -240,5 +240,9 @@ login: url: http://lspm.ningdatech.com/login web: url: http://lspm.ningdatech.com +# 专家报名验证码校验 +expert-registration: + verify-code: + check: false