|
@@ -56,11 +56,10 @@ public class RtkAccountServiceImpl extends ServiceImpl<IRtkAccountMapper, RtkAcc
|
|
|
sendDingDingMsg(0);
|
|
|
throw new BusinessException(ResultCode.RTK_SN_CODE_NOT_EXIT);
|
|
|
}
|
|
|
- long count = this.count();
|
|
|
- modelThreshold(count,list.size() -1);
|
|
|
RtkAccount rtkAccount = list.get(0);
|
|
|
updateAccountStatus(rtkAccount.getId(),2);
|
|
|
redisUtil.set(redisKey,JSONObject.toJSONString(rtkAccount));
|
|
|
+ modelThreshold(list.size() -1);
|
|
|
return rtkAccount;
|
|
|
}
|
|
|
|
|
@@ -72,8 +71,8 @@ public class RtkAccountServiceImpl extends ServiceImpl<IRtkAccountMapper, RtkAcc
|
|
|
this.update(wrapper1);
|
|
|
}
|
|
|
|
|
|
- private void modelThreshold(long count, int size) {
|
|
|
- BigDecimal totalCount = new BigDecimal(count);
|
|
|
+ private void modelThreshold( int size) {
|
|
|
+ BigDecimal totalCount = new BigDecimal(this.count());
|
|
|
BigDecimal dbCount = new BigDecimal(size);
|
|
|
|
|
|
BigDecimal divideCount = totalCount.divide(dbCount).setScale(2, RoundingMode.HALF_DOWN);
|