| | |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.ruoyi.common.basic.PageInfo; |
| | | import com.ruoyi.common.config.SmsProperties; |
| | | import com.ruoyi.common.constant.AmountConstant; |
| | | import com.ruoyi.common.constant.CacheConstants; |
| | | import com.ruoyi.common.core.redis.RedisCache; |
| | |
| | | |
| | | @Resource |
| | | SmsUtil smsUtil; |
| | | |
| | | @Resource |
| | | SmsProperties smsProperties; |
| | | public PageInfo<TBillDto> queryPage(TBillQuery query){ |
| | | PageInfo<TBill> pageInfo = new PageInfo<>(query.getPageNum(), query.getPageSize()); |
| | | PageInfo<TBillDto> info = tBillMapper.page(pageInfo, query); |
| | |
| | | for (String billId : dto.getBillIds()) { |
| | | TBillDto bill = getDetailByBillId(billId); |
| | | if (bill.getSmsLastTime()!=null |
| | | && (System.currentTimeMillis()-bill.getSmsLastTime().getTime()<smsUtil.getPro().getBillSmsDelayPeriod()*60*1000L)){ |
| | | && (System.currentTimeMillis()-bill.getSmsLastTime().getTime()<smsProperties.getBillSmsDelayPeriod()*60*1000L)){ |
| | | throw new ServiceException("有账单最近一次发送的时间是:"+DateUtils.parseDateToStr(DateUtils.YYYY_MM_DD_HH_MM_SS,bill.getSmsLastTime())); |
| | | } |
| | | if (StringUtils.isEmpty(bill.getPhone())){ |
| | |
| | | for (String billId : dto.getBillIds()) { |
| | | TBillDto bill = getDetailByBillId(billId); |
| | | if (bill.getSmsLastTime()!=null |
| | | && (System.currentTimeMillis()-bill.getSmsLastTime().getTime()<smsUtil.getPro().getBillMailDelayPeriod()*60*1000L)){ |
| | | && (System.currentTimeMillis()-bill.getSmsLastTime().getTime()<smsProperties.getBillMailDelayPeriod()*60*1000L)){ |
| | | throw new ServiceException("有账单最近一次发送的时间是:"+DateUtils.parseDateToStr(DateUtils.YYYY_MM_DD_HH_MM_SS,bill.getSmsLastTime())); |
| | | } |
| | | if (StringUtils.isEmpty(bill.getEmail())){ |