| | |
| | | // } |
| | | |
| | | @Override |
| | | public boolean sendSmsCodeText(String phone, PhoneCodeTypeParam param) { |
| | | public boolean sendSmsCodeText(String phone, PhoneCodeTypeParam param,Long userId) { |
| | | Config config = configService.selectConfigByCode("SMSNotification"); |
| | | if (Cools.isEmpty(config) || config.getValue().equals("false")) { |
| | | if (Cools.isEmpty(config) || !config.getValue().equals("true")) { |
| | | return true; |
| | | } |
| | | String randomNum = param.code; |
| | |
| | | smsCode.setCode(randomNum); |
| | | smsCode.setStatus(0); |
| | | smsCode.setCreateTime(new Date()); |
| | | smsCode.setUserId(userId); |
| | | if (this.baseMapper.insert(smsCode) <= 0) { |
| | | return false; |
| | | } |