| | |
| | | import com.ruoyi.common.constant.AmountConstant; |
| | | import com.ruoyi.common.constant.CacheConstants; |
| | | import com.ruoyi.common.core.redis.RedisCache; |
| | | import com.ruoyi.common.enums.DisabledEnum; |
| | | import com.ruoyi.common.exception.ServiceException; |
| | | import com.ruoyi.common.utils.*; |
| | | import com.ruoyi.common.utils.uuid.UUID; |
| | |
| | | if (presist.getPayFeesStatus().equals("3")){ |
| | | throw new ServiceException("该账单已缴费完成"); |
| | | } |
| | | |
| | | switch (type){ |
| | | // 仅更新除金额字段外的属性 |
| | | case 1: |
| | |
| | | .subtract(save.getPayFeesMoney()); |
| | | save.setOutstandingMoney(outstand); |
| | | //抵扣金额就是缴费金额 |
| | | save.setDeductionMoney(tBill.getPayableFeesMoney()); |
| | | save.setDeductionMoney(tBill.getPayFeesMoney()); |
| | | save.setPreOutstand(presist.getOutstandingMoney()); |
| | | if (outstand.compareTo(BigDecimal.ZERO)<=0){ |
| | | save.setPayFeesStatus("3"); |
| | |
| | | break; |
| | | |
| | | } |
| | | save.setBusinessDeptId(presist.getBusinessDeptId()); |
| | | updateById(save); |
| | | return save; |
| | | }finally { |
| | |
| | | @Override |
| | | @Transactional(rollbackFor = Exception.class) |
| | | public void saveBill(TbillSaveDto bill) { |
| | | bill.setManualAddition(DisabledEnum.YES.getCode()); |
| | | save(bill); |
| | | if (bill.getBillType().equals("3")){ |
| | | if (bill.getDetails()==null || bill.getDetails().size()==0){ |
| | |
| | | } |
| | | |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 根据发票编号查询账单列表 |
| | |
| | | * @return |
| | | */ |
| | | @Override |
| | | public List<ScreenRentRankVO> getStreetRentRank() { |
| | | return baseMapper.getStreetRentRank(); |
| | | public List<ScreenRentRankVO> getStreetRentRank(String businessDeptId) { |
| | | return baseMapper.getStreetRentRank(businessDeptId); |
| | | } |
| | | /** |
| | | * 查询季付账单 |
| | | * @param businessDeptId |
| | | * @return |
| | | */ |
| | | @Override |
| | | public List<TBill> getJiFuBillList(String businessDeptId) { |
| | | return baseMapper.getJiFuBillList(businessDeptId,null,null); |
| | | } |
| | | |
| | | /** |
| | | * 查询当前季度的季付账单 |
| | | * @param businessDeptId |
| | | * @param first |
| | | * @param last |
| | | * @return |
| | | */ |
| | | @Override |
| | | public List<TBill> getJiFuBillListByTime(String businessDeptId, Date first, Date last) { |
| | | return baseMapper.getJiFuBillList(businessDeptId,first,last); |
| | | } |
| | | |
| | | @Override |
| | |
| | | // flow.setCreateBy(SecurityUtils.getUsername()); |
| | | // tFlowManagementService.save(flow); |
| | | } |
| | | |
| | | |
| | | } |