BUGFIX: 用户支付后获取账号到期时间为空,无法更新账号信息
This commit is contained in:
@@ -2788,7 +2788,8 @@ public class AccountServiceImpl extends ServiceImpl<AccountMapper, Account> impl
|
|||||||
public boolean updateAccountValidity(Long accountId, Long currentPeriodEnd){
|
public boolean updateAccountValidity(Long accountId, Long currentPeriodEnd){
|
||||||
// 不管当前用户的账号是否到期,都根据付款信息重置账号到期时间
|
// 不管当前用户的账号是否到期,都根据付款信息重置账号到期时间
|
||||||
Account account = accountMapper.selectById(accountId);
|
Account account = accountMapper.selectById(accountId);
|
||||||
if (account.getValidEndTime().equals(currentPeriodEnd * 1000)){
|
if (!Objects.isNull(account.getValidEndTime())
|
||||||
|
&& account.getValidEndTime().equals(currentPeriodEnd * 1000)){
|
||||||
return false;
|
return false;
|
||||||
}else {
|
}else {
|
||||||
account.setValidEndTime(currentPeriodEnd * 1000);
|
account.setValidEndTime(currentPeriodEnd * 1000);
|
||||||
|
|||||||
Reference in New Issue
Block a user