From 0c1ac49f859a0570a19f267d6def82100cb39860 Mon Sep 17 00:00:00 2001
From: k94314517 <8417338+k94314517@user.noreply.gitee.com>
Date: 星期一, 01 四月 2024 18:15:43 +0800
Subject: [PATCH] git ch

---
 server/service/src/main/java/com/doumee/service/business/impl/InsuranceApplyServiceImpl.java |    2 +-
 server/service/src/main/java/com/doumee/core/annotation/excel/ExcelExporter.java             |   14 +++++++-------
 server/service/src/main/java/com/doumee/service/business/impl/UnionApplyServiceImpl.java     |   15 ++++++++++++---
 3 files changed, 20 insertions(+), 11 deletions(-)

diff --git a/server/service/src/main/java/com/doumee/core/annotation/excel/ExcelExporter.java b/server/service/src/main/java/com/doumee/core/annotation/excel/ExcelExporter.java
index b5bf545..ad906fc 100644
--- a/server/service/src/main/java/com/doumee/core/annotation/excel/ExcelExporter.java
+++ b/server/service/src/main/java/com/doumee/core/annotation/excel/ExcelExporter.java
@@ -1139,13 +1139,13 @@
                 sheet.setColumnWidth(i, ((i==3|| i== 4|| i== 5 )?16:8) * 2 * 256);
             }
             sheet.createFreezePane(0, 1);
-            sheet.addMergedRegion(new CellRangeAddress(0   ,0,0,6));
+            sheet.addMergedRegion(new CellRangeAddress(0   ,0,0,5));
             Row title = sheet.createRow(0);
             title.setHeight((short) 2000);
             Cell c = title.createCell(0);
             c.setCellValue(sheetName);
             configFirstCell(sxssfWorkbook,c);
-            for (int i = 0; i < 8; i++) {
+            for (int i = 0; i < 6; i++) {
                 if(i>0){
                     title.createCell(i).setCellValue("");
                 }
@@ -1154,7 +1154,7 @@
             Row header1 = sheet.createRow(1);
             header1.createCell(0).setCellValue("鎶曚繚浜�");
             header1.createCell(1).setCellValue("鎶ヤ繚闄╀汉");
-            header1.createCell(2).setCellValue("鎶曚繚浜烘暟");
+            header1.createCell(2).setCellValue("");
             header1.createCell(3).setCellValue("淇濋櫓鏂规");
             header1.createCell(4).setCellValue("淇濋櫓鐢熸晥璧锋湡");
             header1.createCell(5).setCellValue("淇濋櫓鐢熸晥姝㈡湡");
@@ -1192,8 +1192,8 @@
                 header5.createCell(1).setCellValue(StringUtils.defaultString(addModel.getMemberName(),""));
                 header5.createCell(2).setCellValue(Constants.equalsInteger(addModel.getSex(),0)?"鐢�":(Constants.equalsInteger(addModel.getSex(),1)?"濂�":"-"));
                 header5.createCell(3).setCellValue(StringUtils.defaultString(addModel.getIdcardNo(),""));
-                header5.createCell(6).setCellValue(StringUtils.defaultString(addModel.getDuName(),""));
-                header5.createCell(7).setCellValue(StringUtils.defaultString(addModel.getWorkTypeName(),""));
+                header5.createCell(4).setCellValue(StringUtils.defaultString(addModel.getDuName(),""));
+                header5.createCell(5).setCellValue(StringUtils.defaultString(addModel.getWorkTypeName(),""));
                 for (int i = 0; i < 6; i++) {
                     configDataCell(sxssfWorkbook,header5.getCell(i));
                 }
@@ -1214,7 +1214,7 @@
                 configInfoCell(sxssfWorkbook,header6.getCell(i),HorizontalAlignment.LEFT);
             }
             header6.setHeight((short) 2000);
-            sheet.addMergedRegion(new CellRangeAddress(rowIndex ,rowIndex,0,7));
+            sheet.addMergedRegion(new CellRangeAddress(rowIndex ,rowIndex,0,5));
             Row header7= sheet.createRow(rowIndex+1);
             header7.setHeight((short) 3000);
             header7.createCell(0).setCellValue("鎶曚繚浼佷笟绛剧珷 锛�                            \n \n \n" +"鏃ユ湡锛�     骞�     鏈�     鏃�    ");
@@ -1224,7 +1224,7 @@
                 }
                 configInfoCell(sxssfWorkbook,header7.getCell(i),HorizontalAlignment.RIGHT);
             }
-            sheet.addMergedRegion(new CellRangeAddress(rowIndex+1 ,rowIndex+1,0,7));
+            sheet.addMergedRegion(new CellRangeAddress(rowIndex+1 ,rowIndex+1,0,5));
 
             //涓存椂缂撳啿鍖�
             ByteArrayOutputStream out = new ByteArrayOutputStream();
diff --git a/server/service/src/main/java/com/doumee/service/business/impl/InsuranceApplyServiceImpl.java b/server/service/src/main/java/com/doumee/service/business/impl/InsuranceApplyServiceImpl.java
index 6e086af..53cd185 100644
--- a/server/service/src/main/java/com/doumee/service/business/impl/InsuranceApplyServiceImpl.java
+++ b/server/service/src/main/java/com/doumee/service/business/impl/InsuranceApplyServiceImpl.java
@@ -2447,7 +2447,7 @@
                 .leftJoin(Worktype.class,Worktype::getId,ApplyDetail::getWorktypeId)
                 .leftJoin(DispatchUnit.class,DispatchUnit::getId,ApplyDetail::getDuId)
                 .isNull(ApplyDetail::getFromId)
-                .eq(ApplyDetail::getId,model.getId())
+                .eq(ApplyDetail::getApplyId,model.getId())
         );
         model.setApplyDetailList(applyDetailList);
         return model;
diff --git a/server/service/src/main/java/com/doumee/service/business/impl/UnionApplyServiceImpl.java b/server/service/src/main/java/com/doumee/service/business/impl/UnionApplyServiceImpl.java
index 138b050..be480d9 100644
--- a/server/service/src/main/java/com/doumee/service/business/impl/UnionApplyServiceImpl.java
+++ b/server/service/src/main/java/com/doumee/service/business/impl/UnionApplyServiceImpl.java
@@ -463,15 +463,24 @@
         //鍚堝苟鍗曠姸鎬佸浜庡緟鎶曚繚
         if(unionApply.getStatus().equals(Constants.UnionApplyStatus.UPLOAD_INSURANCE_POLICY.getKey())
         || unionApply.getStatus().equals(Constants.UnionApplyStatus.WAIT_SIGNATURE.getKey())){
-            //TODO 鍒犻櫎浼佷笟鎶曚繚鍗曠殑 绛剧讲鏁版嵁
-
+            multifileMapper.delete(new QueryWrapper<Multifile>()
+                    .lambda()
+                    .apply(" multifile.id in ( select i.id  from insurance_apply i where i.UNION_APPLY_ID = "+unionApply.getId()+" ) ")
+                    .eq(Multifile::getObjType,Constants.MultiFile.COMPANY_TBD_SIGNED.getKey()));
         }
         insuranceApplyJoinMapper.update(null,new UpdateWrapper<InsuranceApply>().lambda()
                 .set(InsuranceApply::getUnionApplyId,null)
                 .set(InsuranceApply::getCheckDate,new Date())
+                .set(unionApply.getStatus().equals(Constants.UnionApplyStatus.UPLOAD_INSURANCE_POLICY.getKey())
+                        || unionApply.getStatus().equals(Constants.UnionApplyStatus.WAIT_SIGNATURE.getKey()),
+                        InsuranceApply::getUnionApplyTbdStatus,Constants.ZERO)
+                .set(unionApply.getStatus().equals(Constants.UnionApplyStatus.UPLOAD_INSURANCE_POLICY.getKey())
+                        || unionApply.getStatus().equals(Constants.UnionApplyStatus.WAIT_SIGNATURE.getKey()),
+                        InsuranceApply::getApplyTbdNo,null)
                 .set(InsuranceApply::getCheckUserId,user.getId())
                 .set(InsuranceApply::getStatus,Constants.InsuranceApplyStatus.WTB_BUSINESS_CHECK_PASS.getKey())
-                .eq(InsuranceApply::getUnionApplyId,unionApply.getId()));
+                .eq(InsuranceApply::getUnionApplyId,unionApply.getId())
+        );
 
         applyDetailJoinMapper.update(null,new UpdateWrapper<ApplyDetail>().lambda()
                 .set(ApplyDetail::getUnionApplyId,null)

--
Gitblit v1.9.3