测试环境 万能验证码 147258
This commit is contained in:
parent
957682ef41
commit
65769b71d1
|
|
@ -68,6 +68,7 @@ import lombok.extern.slf4j.Slf4j;
|
||||||
import org.apache.commons.codec.digest.DigestUtils;
|
import org.apache.commons.codec.digest.DigestUtils;
|
||||||
import org.apache.commons.lang.StringUtils;
|
import org.apache.commons.lang.StringUtils;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.beans.factory.annotation.Value;
|
||||||
import org.springframework.stereotype.Service;
|
import org.springframework.stereotype.Service;
|
||||||
import org.springframework.transaction.annotation.Transactional;
|
import org.springframework.transaction.annotation.Transactional;
|
||||||
import weixin.popular.api.SnsAPI;
|
import weixin.popular.api.SnsAPI;
|
||||||
|
|
@ -116,6 +117,10 @@ public class UserServiceImpl extends ServiceImpl<UserDao, UserEntity> implements
|
||||||
private DiscSpinningService discSpinningService;
|
private DiscSpinningService discSpinningService;
|
||||||
@Autowired
|
@Autowired
|
||||||
private SysUserService sysUserService;
|
private SysUserService sysUserService;
|
||||||
|
|
||||||
|
@Value("${spring.profiles.active}")
|
||||||
|
private String profiles;
|
||||||
|
|
||||||
private ReentrantReadWriteLock reentrantReadWriteLock = new ReentrantReadWriteLock(true);
|
private ReentrantReadWriteLock reentrantReadWriteLock = new ReentrantReadWriteLock(true);
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
@ -902,7 +907,14 @@ public class UserServiceImpl extends ServiceImpl<UserDao, UserEntity> implements
|
||||||
if (StringUtils.isEmpty(msg)) {
|
if (StringUtils.isEmpty(msg)) {
|
||||||
return Result.error("验证码不能为空!");
|
return Result.error("验证码不能为空!");
|
||||||
}
|
}
|
||||||
Msg msg1 = msgDao.findByPhoneAndCode(phone, msg);
|
Msg msg1 = null;
|
||||||
|
if (!"prod".equals(profiles) && !"147258".equals(msg)) {
|
||||||
|
msg1 = msgDao.findByPhoneAndCode(phone, msg);
|
||||||
|
if (msg1 == null) {
|
||||||
|
return Result.error("验证码不正确!");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if (msg1 == null) {
|
if (msg1 == null) {
|
||||||
return Result.error("验证码不正确!");
|
return Result.error("验证码不正确!");
|
||||||
}
|
}
|
||||||
|
|
@ -1509,7 +1521,7 @@ public class UserServiceImpl extends ServiceImpl<UserDao, UserEntity> implements
|
||||||
userMoneyDetails.setMoneyType(1);
|
userMoneyDetails.setMoneyType(1);
|
||||||
boolean ret = userMoneyDetailsService.save(userMoneyDetails);
|
boolean ret = userMoneyDetailsService.save(userMoneyDetails);
|
||||||
if (ret) {
|
if (ret) {
|
||||||
ThreadUtil.execAsync(()->{
|
ThreadUtil.execAsync(() -> {
|
||||||
discSpinningService.withdrawAsync(entity, money.doubleValue(), "[提现]");
|
discSpinningService.withdrawAsync(entity, money.doubleValue(), "[提现]");
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue