TASK:试用时间;
This commit is contained in:
@@ -516,7 +516,11 @@ public class AccountServiceImpl extends ServiceImpl<AccountMapper, Account> impl
|
||||
account.setIsTrial(1);
|
||||
account.setIsBeginner(1);
|
||||
account.setValidStartTime(System.currentTimeMillis());
|
||||
account.setValidEndTime(Instant.now().plus(5, ChronoUnit.DAYS).toEpochMilli());
|
||||
if (StringUtils.isNotBlank(accountTrialDTO.getRef())) {
|
||||
account.setValidEndTime(Instant.now().plus(14, ChronoUnit.DAYS).toEpochMilli());
|
||||
}else {
|
||||
account.setValidEndTime(Instant.now().plus(5, ChronoUnit.DAYS).toEpochMilli());
|
||||
}
|
||||
accountMapper.updateById(account);
|
||||
}else {
|
||||
account.setUserName(trialOrder.getUserName());
|
||||
@@ -524,7 +528,11 @@ public class AccountServiceImpl extends ServiceImpl<AccountMapper, Account> impl
|
||||
account.setUserEmail(trialOrder.getEmail());
|
||||
account.setLanguage(Language.ENGLISH.name());
|
||||
account.setValidStartTime(System.currentTimeMillis());
|
||||
account.setValidEndTime(Instant.now().plus(5, ChronoUnit.DAYS).toEpochMilli());
|
||||
if (StringUtils.isNotBlank(accountTrialDTO.getRef())) {
|
||||
account.setValidEndTime(Instant.now().plus(14, ChronoUnit.DAYS).toEpochMilli());
|
||||
}else {
|
||||
account.setValidEndTime(Instant.now().plus(5, ChronoUnit.DAYS).toEpochMilli());
|
||||
}
|
||||
account.setCreateDate(new Date());
|
||||
account.setIsTrial(1);
|
||||
account.setIsBeginner(1);
|
||||
|
||||
Reference in New Issue
Block a user