From c3892d8e7378ea9441689ebe7009b3e02160b7a1 Mon Sep 17 00:00:00 2001 From: liujie <1793218484@qq.com> Date: 星期五, 11 七月 2025 10:47:28 +0800 Subject: [PATCH] 2.0优化 和修改bug --- springcloud_k8s_panzhihuazhihuishequ/service_westcommittee/src/main/java/com/panzhihua/westcommittee/service/impl/ComplaintServiceImpl.java | 28 ++++++++++++++++++++++++---- 1 files changed, 24 insertions(+), 4 deletions(-) diff --git a/springcloud_k8s_panzhihuazhihuishequ/service_westcommittee/src/main/java/com/panzhihua/westcommittee/service/impl/ComplaintServiceImpl.java b/springcloud_k8s_panzhihuazhihuishequ/service_westcommittee/src/main/java/com/panzhihua/westcommittee/service/impl/ComplaintServiceImpl.java index f0388c5..60f2e20 100644 --- a/springcloud_k8s_panzhihuazhihuishequ/service_westcommittee/src/main/java/com/panzhihua/westcommittee/service/impl/ComplaintServiceImpl.java +++ b/springcloud_k8s_panzhihuazhihuishequ/service_westcommittee/src/main/java/com/panzhihua/westcommittee/service/impl/ComplaintServiceImpl.java @@ -79,11 +79,13 @@ private final IPartyMemberService partyMemberService; private final IdentityInformationService identityInformationService; private final IDepartmentService departmentService; + private final WestPopUpService westPopUpService; private final RedisUtils redisUtils; @Override - public String saveComplaint(Complaint complaint, LoginUserInfoVO loginUserInfoVO) { + public HashMap<String, String> saveComplaint(Complaint complaint, LoginUserInfoVO loginUserInfoVO) { + HashMap<String, String> map = new HashMap<>(); String timeStr = null; // 获取当前日期(年月日) String datePrefix = new SimpleDateFormat("yyyyMMdd").format(new Date()); @@ -190,8 +192,16 @@ complaint.setReportUserPhone(loginUserInfoVO.getPhone()); complaint.setSuperiorId(loginUserInfoVO.getCommunityId()); - LocalDate localDate = LocalDate.now().plusDays(workOrderItemConfigService.getById(1).getCommunityHandlingTime()); - timeStr = localDate.toString(); + + ComAct byId = comActService.getById(loginUserInfoVO.getCommunityId()); + String name = byId.getName(); + WestPopUp one = westPopUpService.getOne(new LambdaQueryWrapper<WestPopUp>().eq(WestPopUp::getName, name)); + + if(one!=null){ + map.put("name", one.getDeptName()); + map.put("phone", one.getPhone()); + } + } @@ -225,7 +235,11 @@ complaint.setNowLevelSms(0); // 保存诉求记录 save(complaint); - return timeStr; + + + + + return map; } @Override @@ -769,6 +783,9 @@ //已办结,显示评价按钮 int count = complaintCommentService.count(new LambdaQueryWrapper<ComplaintComment>().eq(ComplaintComment::getComplaintId, detail.getId()).eq(ComplaintComment::getDelFlag, 0)); + //查询评价 + ComplaintComment comment = complaintCommentService.lambdaQuery().eq(ComplaintComment::getComplaintId, id).last("LIMIT 1").one(); + detail.setComplaintComment(comment); if (detail.getStatus() == 3 && 0 == count) { if (systemUserByPhone.isPresent()) { if (accountLevel.compareTo(detail.getNowLevel()) == 0) { @@ -1232,6 +1249,9 @@ complaint.setRemark(complaintReporAuditDTO.getRemark()); complaint.setNowLevelTime(new Date()); complaint.setNowLevelSms(0); + if (StringUtils.isEmpty(complaint.getProblemType())) { + complaint.setProblemType(complaintReporAuditDTO.getProblemType()); + } // 分配流转 ComplaintFlow complaintFlow = new ComplaintFlow(); -- Gitblit v1.7.1