From 980052523e461ba3745a6a0b73bd2b309e1eb879 Mon Sep 17 00:00:00 2001 From: xuhy <3313886187@qq.com> Date: 星期四, 03 四月 2025 15:18:04 +0800 Subject: [PATCH] 开票 --- ruoyi-applet/src/main/java/com/ruoyi/web/controller/api/IndexController.java | 14 ++++++++++++++ 1 files changed, 14 insertions(+), 0 deletions(-) diff --git a/ruoyi-applet/src/main/java/com/ruoyi/web/controller/api/IndexController.java b/ruoyi-applet/src/main/java/com/ruoyi/web/controller/api/IndexController.java index 989234b..a8bcb1d 100644 --- a/ruoyi-applet/src/main/java/com/ruoyi/web/controller/api/IndexController.java +++ b/ruoyi-applet/src/main/java/com/ruoyi/web/controller/api/IndexController.java @@ -202,6 +202,7 @@ myToDoVO.setStartTime(DateUtils.localDateTimeToStringYear(contract.getStartTime())); myToDoVO.setPropertyRightPerson(tHouse.getPropertyRightPerson()); myToDoVO.setPhone(tHouse.getPhone()); + myToDoVO.setRentalReturnStatus(tHouse.getRentalReturnStatus() == null ? "1" : tHouse.getRentalReturnStatus()); List<TBill> billList = bills.stream().filter(e -> e.getContractId().equals(contract.getId())).collect(Collectors.toList()); List<PayListVO> payList = new ArrayList<>(); for (TBill tBill : billList) { @@ -295,6 +296,19 @@ // 添加验收记录 dto.setCheckPerson(tokenService.getLoginUser().getUser().getNickName()); checkAcceptRecordService.updateById(dto); + TCheckAcceptRecord checkAcceptRecord = checkAcceptRecordService.getById(dto.getId()); + TContract contract = contractService.getById(checkAcceptRecord.getContractId()); + // 添加账单 + TBill tBill = new TBill(); + tBill.setContractId(checkAcceptRecord.getContractId()); + tBill.setContractNumber(contract.getContractNumber()); + tBill.setPayableFeesMoney(dto.getCheckMoney()); + tBill.setPayableFeesTime(LocalDate.now()); + tBill.setPayFeesStatus("1"); + tBill.setBillType("4"); + tBill.setOverDays(0); + tBill.setOutstandingMoney(dto.getCheckMoney()); + billService.save(tBill); return R.ok(); } /** -- Gitblit v1.7.1