| | |
| | | import com.ruoyi.common.enums.SubmitStatusEnum; |
| | | import com.ruoyi.common.exception.ServiceException; |
| | | import com.ruoyi.system.mapper.TCheckAcceptRecordMapper; |
| | | import com.ruoyi.system.model.TBill; |
| | | import com.ruoyi.system.model.TCheckAcceptRecord; |
| | | import com.ruoyi.system.model.TContract; |
| | | import com.ruoyi.system.model.TContractRentType; |
| | | import com.ruoyi.system.service.ISysRoleService; |
| | | import com.ruoyi.system.service.TBillService; |
| | | import com.ruoyi.system.service.TContractRentTypeService; |
| | | import com.ruoyi.system.service.TContractService; |
| | | import com.ruoyi.system.model.*; |
| | | import com.ruoyi.system.service.*; |
| | | import com.ruoyi.system.task.base.QuartzManager; |
| | | import com.ruoyi.system.task.base.TimeJobType; |
| | | import com.ruoyi.system.task.jobs.StateProcessJob; |
| | |
| | | private final TContractRentTypeService contractRentTypeService; |
| | | private final TBillService billService; |
| | | private final TCheckAcceptRecordMapper checkAcceptRecordMapper; |
| | | private final THouseService houseService; |
| | | |
| | | public static void main(String[] args) { |
| | | // LocalDate localDate1 = LocalDate.now().withYear(2025).withMonth(4).withDayOfMonth(1); |
| | |
| | | int submitStatus = status == 0 ? 3 : (status == 1 ? 4 : 5); |
| | | contractService.updateContractAuditStatus(processParameter.getString("projectId"), submitStatus); |
| | | TContract contract = contractService.getById(processParameter.getString("projectId")); |
| | | // 修改房屋状态 |
| | | THouse house = houseService.getById(contract.getHouseId()); |
| | | if(Objects.nonNull(house)){ |
| | | house.setLeaseStatus("2"); |
| | | houseService.updateById(house); |
| | | } |
| | | List<TContractRentType> contractRentTypes = contractRentTypeService.list(); |
| | | TContractRentType tContractRentType = contractRentTypes.stream().filter(e -> e.getContractId().equals(contract.getId())).findFirst().orElse(null); |
| | | |
| | |
| | | if (beforeBill.getEndTime().plusMonths(contract.getPayType().equals("1") ? 1 : contract.getPayType().equals("2") ? 3 : 12).getDayOfMonth() <= 15) { |
| | | tBill.setPayableFeesTime(contract.getEndTime().toLocalDate()); |
| | | } else { |
| | | tBill.setPayableFeesTime((contract.getPayType().equals("1") ? |
| | | beforeBill.getEndTime().plusMonths(1).withDayOfMonth(15).toLocalDate() : contract.getPayType().equals("2") ? |
| | | beforeBill.getEndTime().plusMonths(3).withDayOfMonth(15).toLocalDate() : beforeBill.getEndTime().withDayOfMonth(15).plusMonths(12).toLocalDate())); |
| | | tBill.setPayableFeesTime((contract.getPayType().equals("1") || contract.getPayType().equals("2")? |
| | | beforeBill.getEndTime().plusMonths(1).withDayOfMonth(15).toLocalDate() : beforeBill.getEndTime().withDayOfMonth(15).plusMonths(12).toLocalDate())); |
| | | } |
| | | tBill.setContractId(contract.getId()); |
| | | if (contract.getIsIncreasing()) { |