Procházet zdrojové kódy

Merge branch 'dev' of http://git.xayunmei.com/SH-Arbitrate/Arbitrate-Backend into hjb

hejinbo před 2 roky
rodič
revize
f4f7153278

+ 9
- 6
ruoyi-system/src/main/java/com/ruoyi/system/service/impl/SysDeptServiceImpl.java Zobrazit soubor

211
     @Override
211
     @Override
212
     public int insertDept(SysDept dept)
212
     public int insertDept(SysDept dept)
213
     {
213
     {
214
-        SysDept info = deptMapper.selectDeptById(dept.getParentId());
215
-        // 如果父节点不为正常状态,则不允许新增子节点
216
-        if (!UserConstants.DEPT_NORMAL.equals(info.getStatus()))
217
-        {
218
-            throw new ServiceException("部门停用,不允许新增");
214
+        Long parentId = dept.getParentId();
215
+        if(parentId!=null){
216
+            SysDept info = deptMapper.selectDeptById(dept.getParentId());
217
+            // 如果父节点不为正常状态,则不允许新增子节点
218
+            if (!UserConstants.DEPT_NORMAL.equals(info.getStatus()))
219
+            {
220
+                throw new ServiceException("部门停用,不允许新增");
221
+            }
222
+            dept.setAncestors(info.getAncestors() + "," + dept.getParentId());
219
         }
223
         }
220
-        dept.setAncestors(info.getAncestors() + "," + dept.getParentId());
221
         return deptMapper.insertDept(dept);
224
         return deptMapper.insertDept(dept);
222
     }
225
     }
223
 
226
 

+ 32
- 16
ruoyi-system/src/main/java/com/ruoyi/wisdomarbitrate/domain/CaseApplication.java Zobrazit soubor

29
     private Date registerDate;
29
     private Date registerDate;
30
     /** 仲裁方式 */
30
     /** 仲裁方式 */
31
     private Integer arbitratMethod;
31
     private Integer arbitratMethod;
32
+    /**
33
+     * 是否导入,0手动录入,1导入,默认0
34
+     */
35
+    private Integer importFlag;
36
+
37
+    public Integer getImportFlag() {
38
+        return importFlag;
39
+    }
40
+
41
+    public void setImportFlag(Integer importFlag) {
42
+        this.importFlag = importFlag;
43
+    }
32
 
44
 
33
     public String getSelectCaseStatus() {
45
     public String getSelectCaseStatus() {
34
         return selectCaseStatus;
46
         return selectCaseStatus;
91
     /** 申请人主张违约金 */
103
     /** 申请人主张违约金 */
92
     @Excel(name = "申请人主张违约金")
104
     @Excel(name = "申请人主张违约金")
93
     private BigDecimal claimLiquidDamag;
105
     private BigDecimal claimLiquidDamag;
106
+    /** 申请人请求仲裁庭裁决 */
107
+    @Excel(name = "申请人请求仲裁庭裁决",width = 36)
108
+    private String requestRule;
109
+
110
+    /** 是否财产保全申请 */
111
+    @Excel(name = "是否财产保全申请",width = 26,combo= {"是","否"},readConverterExp = "0=否,1=是")
112
+    private Integer properPreser;
94
     /** 申请人仲裁请求及事实和理由 */
113
     /** 申请人仲裁请求及事实和理由 */
95
     @Excel(name = "申请人仲裁请求及事实和理由",width = 36)
114
     @Excel(name = "申请人仲裁请求及事实和理由",width = 36)
96
     private String arbitratClaims;
115
     private String arbitratClaims;
132
     /** 是否需要开庭审理 */
151
     /** 是否需要开庭审理 */
133
     private Integer openCourtHear;
152
     private Integer openCourtHear;
134
 
153
 
135
-    /** 申请人请求仲裁庭裁决 */
136
-    @Excel(name = "申请人请求仲裁庭裁决",width = 36)
137
-    private String requestRule;
154
+
138
     /** 是否仲裁反请求 */
155
     /** 是否仲裁反请求 */
139
     private Integer adjudicaCounter;
156
     private Integer adjudicaCounter;
140
-    /** 是否财产保全申请 */
141
-    private Integer properPreser;
157
+
142
     /** 被申请人是否缺席 */
158
     /** 被申请人是否缺席 */
143
     private Integer isAbsence;
159
     private Integer isAbsence;
144
     /** 是否管辖异议申请 */
160
     /** 是否管辖异议申请 */
582
     /** 姓名 */
598
     /** 姓名 */
583
     @Excel(name = "申请人主体信息-申请人(机构)",width = 26)
599
     @Excel(name = "申请人主体信息-申请人(机构)",width = 26)
584
     private String name;
600
     private String name;
585
-
601
+    /** 身份证号 */
602
+    @Excel(name = "申请人主体信息-代码",width = 26)
603
+    private String identityNum;
604
+    /** 申请人主体信息-法定代表人 */
605
+    @Excel(name = "申请人主体信息-法定代表人",width = 26)
606
+    private String compLegalPerson;
607
+    /** 申请人主体信息-法定代表人 */
608
+    @Excel(name = "申请人主体信息-法定代表人职位",width = 26)
609
+    private String compLegalperPost;
586
     /**
610
     /**
587
      * 申请人主体信息-申请人(机构)id
611
      * 申请人主体信息-申请人(机构)id
588
      */
612
      */
589
     private String nameId;
613
     private String nameId;
590
-    /** 身份证号 */
591
-    @Excel(name = "申请人主体信息-代码",width = 26)
592
-    private String identityNum;
593
 
614
 
594
     /** 联系电话 */
615
     /** 联系电话 */
595
     @Excel(name = "申请人主体信息-联系电话",width = 26)
616
     @Excel(name = "申请人主体信息-联系电话",width = 26)
603
     /** 单位地址 */
624
     /** 单位地址 */
604
     @Excel(name = "申请人主体信息-单位地址",width = 26)
625
     @Excel(name = "申请人主体信息-单位地址",width = 26)
605
     private String workAddress;
626
     private String workAddress;
606
-    /** 申请人主体信息-法定代表人 */
607
-    @Excel(name = "申请人主体信息-法定代表人",width = 26)
608
-    private String compLegalPerson;
609
-    /** 申请人主体信息-法定代表人 */
610
-    @Excel(name = "申请人主体信息-法定代表人职位",width = 26)
611
-    private String compLegalperPost;
627
+
612
     /** 申请人住所 */
628
     /** 申请人住所 */
613
     @Excel(name = "申请人主体信息-住所",width = 26)
629
     @Excel(name = "申请人主体信息-住所",width = 26)
614
     private String residenAffiliAppli;
630
     private String residenAffiliAppli;
664
     @Excel(name = "被申请人主体信息-身份证号",width = 26)
680
     @Excel(name = "被申请人主体信息-身份证号",width = 26)
665
     private String debtorIdentityNum;
681
     private String debtorIdentityNum;
666
     /** 被申请人主体信息-性别 */
682
     /** 被申请人主体信息-性别 */
667
-    @Excel(name = "被申请人主体信息-性别",width = 26)
683
+    @Excel(name = "被申请人主体信息-性别",width = 26,combo= {"男","女"},readConverterExp = "0=男,女=1")
668
     private String responSex;
684
     private String responSex;
669
 
685
 
670
     public Date getResponBirth() {
686
     public Date getResponBirth() {

+ 93
- 43
ruoyi-system/src/main/java/com/ruoyi/wisdomarbitrate/service/impl/CaseApplicationServiceImpl.java Zobrazit soubor

44
 
44
 
45
 import java.io.*;
45
 import java.io.*;
46
 import java.math.BigDecimal;
46
 import java.math.BigDecimal;
47
+import java.math.RoundingMode;
47
 import java.nio.file.Files;
48
 import java.nio.file.Files;
48
 import java.nio.file.Path;
49
 import java.nio.file.Path;
49
 import java.nio.file.StandardCopyOption;
50
 import java.nio.file.StandardCopyOption;
905
     public int editCaseApplication(CaseApplication caseApplication) {
906
     public int editCaseApplication(CaseApplication caseApplication) {
906
         //根据仲裁费用计费规则计算应缴费用
907
         //根据仲裁费用计费规则计算应缴费用
907
         //暂时设置计费比率为0.01
908
         //暂时设置计费比率为0.01
908
-        BigDecimal feeRate = new BigDecimal(0.01);
909
-        BigDecimal feePayable  = caseApplication.getCaseSubjectAmount().multiply(feeRate).setScale(2,BigDecimal.ROUND_HALF_UP);
909
+        BigDecimal feeRate = new BigDecimal("0.01");
910
+        BigDecimal feePayable  = caseApplication.getCaseSubjectAmount().multiply(feeRate).setScale(2, RoundingMode.HALF_UP);
910
         caseApplication.setFeePayable(feePayable);
911
         caseApplication.setFeePayable(feePayable);
911
         caseApplication.setUpdateBy(getUsername());
912
         caseApplication.setUpdateBy(getUsername());
912
 
913
 
969
         return rows;
970
         return rows;
970
     }
971
     }
971
 
972
 
973
+
972
     /**
974
     /**
973
      * 组装申请代理人信息
975
      * 组装申请代理人信息
974
      * @param caseAffiliate
976
      * @param caseAffiliate
1176
                 CaseApplication caseApplication = caseApplicationList.get(i);
1178
                 CaseApplication caseApplication = caseApplicationList.get(i);
1177
 
1179
 
1178
                 // 导入校验
1180
                 // 导入校验
1179
-                importValid(caseApplication);
1181
+                importValid(caseApplication,deptMap);
1180
                 // 校验成功的数据
1182
                 // 校验成功的数据
1181
                 if(StrUtil.isEmpty(caseApplication.getErrorMsg())) {
1183
                 if(StrUtil.isEmpty(caseApplication.getErrorMsg())) {
1182
                     //根据仲裁费用计费规则计算应缴费用
1184
                     //根据仲裁费用计费规则计算应缴费用
1183
                     //暂时设置计费比率为0.01
1185
                     //暂时设置计费比率为0.01
1184
-                    BigDecimal feeRate = new BigDecimal(0.01);
1185
-                    BigDecimal feePayable = caseApplication.getCaseSubjectAmount().multiply(feeRate).setScale(2, BigDecimal.ROUND_HALF_UP);
1186
+                    BigDecimal feeRate = new BigDecimal("0.01");
1187
+                    BigDecimal feePayable = caseApplication.getCaseSubjectAmount().multiply(feeRate).setScale(2, RoundingMode.HALF_UP);
1186
                     caseApplication.setFeePayable(feePayable);
1188
                     caseApplication.setFeePayable(feePayable);
1187
 
1189
 
1188
                     //赋值CaseApplication的案件关联人信息
1190
                     //赋值CaseApplication的案件关联人信息
1189
                     List<CaseAffiliate> caseAffiliatesnew = new ArrayList<>();
1191
                     List<CaseAffiliate> caseAffiliatesnew = new ArrayList<>();
1190
                     // 组装案件关联人信息
1192
                     // 组装案件关联人信息
1191
                     assignmentCaseAffiliates(caseApplication, caseAffiliatesnew, deptMap,roleId);
1193
                     assignmentCaseAffiliates(caseApplication, caseAffiliatesnew, deptMap,roleId);
1192
-
1193
-//                int caseApplicationCount = selectCaseApplicationCount(caseApplication);
1194
-//                if(caseApplicationCount>0){
1195
-//                    failureNum++;
1196
-//                    failureMsg.append("<br/>" + failureNum + "、立案编号 " + caseApplication.getCaseNum() + " 已存在");
1197
-//                }else {
1198
-//                    caseApplicationListinsert.add(caseApplication);
1199
-//                }
1200
-                    if(StrUtil.isEmpty(caseApplication.getErrorMsg())) {
1201
-                        caseApplicationListinsert.add(caseApplication);
1202
-                    }else {
1203
-                        // 拼接错误信息
1204
-                         failureMsg.append("<br/>").append("第").append(i+2).append("行:").append(caseApplication.getErrorMsg().toString());
1205
-
1206
-                    }
1194
+                    caseApplication.setImportFlag(1);
1195
+                    caseApplicationListinsert.add(caseApplication);
1207
                 }else {
1196
                 }else {
1208
                     // 拼接错误信息
1197
                     // 拼接错误信息
1209
                     failureMsg.append("<br/>").append("第").append(i+2).append("行:").append(caseApplication.getErrorMsg().toString());
1198
                     failureMsg.append("<br/>").append("第").append(i+2).append("行:").append(caseApplication.getErrorMsg().toString());
1283
      * @param caseApplication
1272
      * @param caseApplication
1284
      * @param
1273
      * @param
1285
      */
1274
      */
1286
-    private void importValid(CaseApplication caseApplication) {
1275
+    private void importValid(CaseApplication caseApplication,Map<String, Long> deptMap) {
1287
         StringBuilder failureMsg=new StringBuilder();
1276
         StringBuilder failureMsg=new StringBuilder();
1288
         caseApplication.setErrorMsg(failureMsg);
1277
         caseApplication.setErrorMsg(failureMsg);
1289
         // 校验基本字段
1278
         // 校验基本字段
1291
         // 校验申请人信息
1280
         // 校验申请人信息
1292
         validApplicationColumn(caseApplication,failureMsg);
1281
         validApplicationColumn(caseApplication,failureMsg);
1293
         // 校验申请人代理信息
1282
         // 校验申请人代理信息
1294
-        validApplicationAgentColumn(caseApplication,failureMsg);
1283
+        validApplicationAgentColumn(caseApplication,failureMsg,deptMap);
1295
         // 校验被申请人信息
1284
         // 校验被申请人信息
1296
         validDebtorApplicationColumn(caseApplication,failureMsg);
1285
         validDebtorApplicationColumn(caseApplication,failureMsg);
1297
         // 校验被申请人代理信息
1286
         // 校验被申请人代理信息
1382
      * @param caseApplication
1371
      * @param caseApplication
1383
      * @param failureMsg
1372
      * @param failureMsg
1384
      */
1373
      */
1385
-    private void validApplicationAgentColumn(CaseApplication caseApplication, StringBuilder failureMsg) {
1374
+    private void validApplicationAgentColumn(CaseApplication caseApplication, StringBuilder failureMsg,Map<String, Long> deptMap) {
1386
         if( StrUtil.isEmpty(caseApplication.getNameAgent())){
1375
         if( StrUtil.isEmpty(caseApplication.getNameAgent())){
1387
             failureMsg.append("【申请人主体信息-代理人姓名】字段不能为空;");
1376
             failureMsg.append("【申请人主体信息-代理人姓名】字段不能为空;");
1388
         }else if(caseApplication.getNameAgent().length()>50){
1377
         }else if(caseApplication.getNameAgent().length()>50){
1393
         }else if(caseApplication.getIdentityNumAgent().length()>50){
1382
         }else if(caseApplication.getIdentityNumAgent().length()>50){
1394
             failureMsg.append("【申请人主体信息-代理人身份证号】字段超出指定长度,最大长度为50;");
1383
             failureMsg.append("【申请人主体信息-代理人身份证号】字段超出指定长度,最大长度为50;");
1395
         }
1384
         }
1385
+        validAgentInfo(caseApplication,failureMsg,deptMap);
1396
         String contactTelphoneAgent = caseApplication.getContactTelphoneAgent();
1386
         String contactTelphoneAgent = caseApplication.getContactTelphoneAgent();
1397
         if( StrUtil.isEmpty(contactTelphoneAgent)){
1387
         if( StrUtil.isEmpty(contactTelphoneAgent)){
1398
             failureMsg.append("【申请人主体信息-代理人联系电话】字段不能为空;");
1388
             failureMsg.append("【申请人主体信息-代理人联系电话】字段不能为空;");
1405
             failureMsg.append("【申请人主体信息-代理人联系地址】字段超出指定长度,最大长度为50;");
1395
             failureMsg.append("【申请人主体信息-代理人联系地址】字段超出指定长度,最大长度为50;");
1406
         }
1396
         }
1407
     }
1397
     }
1398
+    /**
1399
+     * 校验代理人与组织机构关系
1400
+     * @param caseApplication
1401
+     * @param failureMsg
1402
+     * @return
1403
+     */
1404
+    private void validAgentInfo(CaseApplication caseApplication, StringBuilder failureMsg,Map<String, Long> deptMap) {
1405
+        // 申请机构与代理人都不为空,校验代理人与组织机构关系(代理人必须在该部门下)
1406
+        if (StrUtil.isNotEmpty(caseApplication.getName())&&StrUtil.isNotEmpty(caseApplication.getNameAgent())) {
1407
+            String applicationOrganId="";
1408
+            // 申请机构已经存在
1409
+            if(deptMap.containsKey(caseApplication.getName())){
1410
+                applicationOrganId=String.valueOf(deptMap.get(caseApplication.getName()));
1411
+            }
1412
+            // 根据代理人身份证去用户表查询
1413
+            SysUser agentUser = sysUserMapper.selectUserByIdCard(caseApplication.getIdentityNumAgent());
1414
+            // 代理人的部门和申请机构不匹配
1415
+            if (null != agentUser.getDeptId() && !String.valueOf(agentUser.getDeptId()).equals(applicationOrganId)) {
1416
+//                return "该申请代理人已在"+agentUser.getDeptName()+"申请机构下存在,请检查填写信息是否正确";
1417
+                if (null != agentUser.getDept() && StrUtil.isNotEmpty(agentUser.getDept().getDeptName())) {
1418
+                    failureMsg.append("该申请代理人已在【").append(agentUser.getDept().getDeptName()).append("】申请机构下存在,请检查填写信息是否正确");
1419
+                } else {
1420
+                    failureMsg.append( "该申请代理人已存在,与申请机构不匹配,请检查填写信息是否正确");
1421
+                }
1422
+            }
1408
 
1423
 
1424
+        }
1425
+    }
1409
     /**
1426
     /**
1410
      * 校验申请人主题信息
1427
      * 校验申请人主题信息
1411
      * @param caseApplication
1428
      * @param caseApplication
1806
      */
1823
      */
1807
     @Override
1824
     @Override
1808
     public String sendRoomNoMessage(SendRoomNoMessageVO messageVO) {
1825
     public String sendRoomNoMessage(SendRoomNoMessageVO messageVO) {
1809
-        CaseAffiliate caseAffiliate = caseAffiliateMapper.selectCaseAffiliateByIdentityType(messageVO.getId(), 2);
1810
-        if(null==caseAffiliate){
1811
-            return "被申请人不存在";
1826
+        CaseAffiliate caseAffiliateSelect=new CaseAffiliate();
1827
+        caseAffiliateSelect.setCaseAppliId(messageVO.getId());
1828
+        List<CaseAffiliate> caseAffiliates= caseAffiliateMapper.selectCaseAffiliate(caseAffiliateSelect);
1829
+        if(CollectionUtil.isEmpty(caseAffiliates)){
1830
+            return "申请人、被申请人不存在";
1812
         }
1831
         }
1813
         CaseApplication caseApplication = new CaseApplication();
1832
         CaseApplication caseApplication = new CaseApplication();
1814
         caseApplication.setId(messageVO.getId());
1833
         caseApplication.setId(messageVO.getId());
1815
         CaseApplication caseApplicationselect = caseApplicationMapper.selectCaseApplication(caseApplication);
1834
         CaseApplication caseApplicationselect = caseApplicationMapper.selectCaseApplication(caseApplication);
1835
+        String returnResult="短信发送成功";
1816
 
1836
 
1817
         //发送短信通知
1837
         //发送短信通知
1818
         SmsUtils.SendSmsRequest request = new SmsUtils.SendSmsRequest();
1838
         SmsUtils.SendSmsRequest request = new SmsUtils.SendSmsRequest();
1819
         request.setTemplateId("1952136");
1839
         request.setTemplateId("1952136");
1820
-        // 1948332 普通短信 尊敬的{1}用户,您的{2}仲裁案件,开庭审理房间号为{3},请在微信内打开https://miniapp-3gpama6l759911ef-1321289474.tcloudbaseapp.com/jump-mp.html 请知晓,如非本人操作,请忽略本短信。
1821
-        request.setPhone(caseAffiliate.getContactTelphone());
1822
-        request.setTemplateParamSet(new String[]{caseAffiliate.getName(), caseApplicationselect.getCaseNum(), messageVO.getRoomNo()});
1823
-        if (SmsUtils.sendSms(request)){
1824
-            //保存短信发送记录
1825
-            SmsSendRecord smsSendRecord = new SmsSendRecord();
1826
-            smsSendRecord.setCaseId(messageVO.getId());
1827
-            smsSendRecord.setCaseNum(caseApplicationselect.getCaseNum());
1828
-            smsSendRecord.setPhone(request.getPhone());
1829
-            smsSendRecord.setSendTime(new Date());
1830
-            String content="尊敬的"+caseAffiliate.getName()+"用户,您的"+ caseApplicationselect.getCaseNum()+"仲裁案件,开庭审理房间号为"+ messageVO.getRoomNo()+",请在微信内打开https://miniapp-3gpama6l759911ef-1321289474.tcloudbaseapp.com/jump-mp.html 请知晓,如非本人操作,请忽略本短信。";
1831
-            smsSendRecord.setSendContent(content);
1832
-            smsSendRecord.setCreateBy(getUsername());
1833
-            smsRecordMapper.saveSmsSendRecord(smsSendRecord);
1834
-        }
1835
-        return "短信发送成功";
1840
+        for (CaseAffiliate caseAffiliate : caseAffiliates) {
1841
+            request.setPhone(caseAffiliate.getContactTelphone());
1842
+            request.setTemplateParamSet(new String[]{caseAffiliate.getName(), caseApplicationselect.getCaseNum(), messageVO.getRoomNo()});
1843
+            // 1948332 普通短信 尊敬的{1}用户,您的{2}仲裁案件,开庭审理房间号为{3},请在微信内打开https://miniapp-3gpama6l759911ef-1321289474.tcloudbaseapp.com/jump-mp.html 请知晓,如非本人操作,请忽略本短信。
1844
+            if (SmsUtils.sendSms(request)){
1845
+                //保存短信发送记录
1846
+                SmsSendRecord smsSendRecord = new SmsSendRecord();
1847
+                smsSendRecord.setCaseId(messageVO.getId());
1848
+                smsSendRecord.setCaseNum(caseApplicationselect.getCaseNum());
1849
+                smsSendRecord.setPhone(request.getPhone());
1850
+                smsSendRecord.setSendTime(new Date());
1851
+                String content="尊敬的"+caseAffiliate.getName()+"用户,您的"+ caseApplicationselect.getCaseNum()+"仲裁案件,开庭审理房间号为"+ messageVO.getRoomNo()+",请在微信内打开https://miniapp-3gpama6l759911ef-1321289474.tcloudbaseapp.com/jump-mp.html 请知晓,如非本人操作,请忽略本短信。";
1852
+                smsSendRecord.setSendContent(content);
1853
+                String userName;
1854
+                try {
1855
+                    userName= getUsername();
1856
+                } catch (Exception e) {
1857
+                    userName="admin";
1858
+                }
1859
+                smsSendRecord.setCreateBy(userName);
1860
+                smsRecordMapper.saveSmsSendRecord(smsSendRecord);
1861
+            }else {
1862
+                returnResult= "短信发送失败";
1863
+            }
1864
+        }
1865
+        return returnResult;
1866
+
1836
     }
1867
     }
1837
 
1868
 
1838
     @Override
1869
     @Override
2074
                 caseApplication.setFilearbitraUrl(filearbitraUrl);
2105
                 caseApplication.setFilearbitraUrl(filearbitraUrl);
2075
             }
2106
             }
2076
         }
2107
         }
2108
+
2077
         return caseApplication;
2109
         return caseApplication;
2078
     }
2110
     }
2079
 
2111
 
2083
     @Transactional
2115
     @Transactional
2084
     public int pendTralSure(CaseApplication caseApplication) {
2116
     public int pendTralSure(CaseApplication caseApplication) {
2085
 //        caseApplication.setCaseStatus(CaseApplicationConstants.CHECK_ARBITRATION_METHOD);
2117
 //        caseApplication.setCaseStatus(CaseApplicationConstants.CHECK_ARBITRATION_METHOD);
2118
+
2086
         caseApplication.setCaseStatus(CaseApplicationConstants.MODIFY_HEARDATE);
2119
         caseApplication.setCaseStatus(CaseApplicationConstants.MODIFY_HEARDATE);
2087
-        int rows = caseApplicationMapper.submitCaseApplication(caseApplication);
2120
+        Integer isAgreePendTral = caseApplication.getIsAgreePendTral();
2121
+        int rows = 0;
2122
+        //同意组庭
2123
+        if(isAgreePendTral!=null&&isAgreePendTral==1){
2124
+            rows = caseApplicationMapper.submitCaseApplication(caseApplication);
2125
+        }else {
2126
+            List<Arbitrator> arbitrators = caseApplication.getArbitrators();
2127
+            // 仲裁员信息
2128
+            if(arbitrators!=null&&arbitrators.size()>0){
2129
+                List<Long> ids = arbitrators.stream().map(Arbitrator::getId).collect(Collectors.toList());
2130
+                List<String> arbitratorNames = arbitrators.stream().map(Arbitrator::getArbitratorName).collect(Collectors.toList());
2131
+                String idstr = ids.stream().map(Object::toString).collect(Collectors.joining(","));
2132
+                String arbitratorNamestr = arbitratorNames.stream().map(Object::toString).collect(Collectors.joining(","));
2133
+                caseApplication.setArbitratorId(idstr);
2134
+                caseApplication.setArbitratorName(arbitratorNamestr);
2135
+                rows = caseApplicationMapper.submitCaseApplication(caseApplication);
2136
+            }
2137
+        }
2088
 
2138
 
2089
         //发送短信通知
2139
         //发送短信通知
2090
         SmsUtils.SendSmsRequest request = new SmsUtils.SendSmsRequest();
2140
         SmsUtils.SendSmsRequest request = new SmsUtils.SendSmsRequest();

+ 4
- 0
ruoyi-system/src/main/java/com/ruoyi/wisdomarbitrate/utils/CaseLogUtils.java Zobrazit soubor

36
             operLog.setCreateBy(sysUser.getUserName());
36
             operLog.setCreateBy(sysUser.getUserName());
37
             operLog.setCreateNickName(sysUser.getNickName());
37
             operLog.setCreateNickName(sysUser.getNickName());
38
             operLog.setUpdateBy(sysUser.getUserName());
38
             operLog.setUpdateBy(sysUser.getUserName());
39
+        }else {
40
+            operLog.setCreateBy("admin");
41
+            operLog.setCreateNickName("管理员");
42
+            operLog.setUpdateBy("admin");
39
         }
43
         }
40
         operLog.setCaseAppliId(caseAppliId);
44
         operLog.setCaseAppliId(caseAppliId);
41
         operLog.setCaseNode(caseNode);
45
         operLog.setCaseNode(caseNode);

+ 30
- 26
ruoyi-system/src/main/java/com/ruoyi/wisdomarbitrate/utils/FixSelectFlowDetailUtils.java Zobrazit soubor

77
                     caseApplication.setId(sealSignRecord.getCaseAppliId());
77
                     caseApplication.setId(sealSignRecord.getCaseAppliId());
78
 
78
 
79
                     CaseApplication caseApplicationselect = caseApplicationMapper.selectCaseApplication(caseApplication);
79
                     CaseApplication caseApplicationselect = caseApplicationMapper.selectCaseApplication(caseApplication);
80
-                    if(caseApplicationselect.getCaseStatus().intValue()==CaseApplicationConstants.SIGN_ARBITRATION){
81
-                        caseApplication.setCaseStatus(CaseApplicationConstants.ARBITRATED_SEAL);
82
-                        caseApplicationMapper.submitCaseApplication(caseApplication);
80
+                    if(caseApplicationselect!=null){
81
+                        if((caseApplicationselect.getCaseStatus()!=null)&&(caseApplicationselect.getCaseStatus().intValue()==CaseApplicationConstants.SIGN_ARBITRATION)){
82
+                            caseApplication.setCaseStatus(CaseApplicationConstants.ARBITRATED_SEAL);
83
+                            caseApplicationMapper.submitCaseApplication(caseApplication);
83
 
84
 
84
-                        //修改"签署用印记录表"的状态为待用印
85
-                        sealSignRecord.setSignFlowStatus(2);
86
-                        sealSignRecordMapper.updataSealSignRecord(sealSignRecord);
85
+                            //修改"签署用印记录表"的状态为待用印
86
+                            sealSignRecord.setSignFlowStatus(2);
87
+                            sealSignRecordMapper.updataSealSignRecord(sealSignRecord);
88
+                        }
87
                     }
89
                     }
88
 
90
 
89
-
90
                 }
91
                 }
91
                 if((psnsignStatus.intValue()==2)&&(orgsignStatus.intValue()==2)){
92
                 if((psnsignStatus.intValue()==2)&&(orgsignStatus.intValue()==2)){
92
                     //更新立案申请状态为待送达
93
                     //更新立案申请状态为待送达
94
                     caseApplication.setId(sealSignRecord.getCaseAppliId());
95
                     caseApplication.setId(sealSignRecord.getCaseAppliId());
95
 
96
 
96
                     CaseApplication caseApplicationselect = caseApplicationMapper.selectCaseApplication(caseApplication);
97
                     CaseApplication caseApplicationselect = caseApplicationMapper.selectCaseApplication(caseApplication);
97
-                    if(caseApplicationselect.getCaseStatus().intValue()==CaseApplicationConstants.ARBITRATED_SEAL){
98
-                        caseApplication.setCaseStatus(CaseApplicationConstants.ARBITRATION_DELIVERY);
99
-                        //下载审核完成的裁决书,
100
-                        String signFlowId = sealSignRecord.getSignFlowid();
101
-                        EsignHttpResponse fileDownload = SaaSAPIFileUtils.fileDownloadUrl(signFlowId);
102
-                        JsonObject fileDownloadJsonObject = gson.fromJson(fileDownload.getBody(),JsonObject.class);
103
-                        JsonObject fileDownloadData = fileDownloadJsonObject.getAsJsonObject("data");
104
-                        JsonArray filesArray = fileDownloadData.get("files").getAsJsonArray();
105
-                        if(filesArray!=null&&filesArray.size()>0){
106
-                            JsonObject fileObject = (JsonObject)filesArray.get(0);
107
-                            String fileDownloadUrl = fileObject.get("downloadUrl").toString();
108
-                            //修改"签署用印记录表"的状态为签署完成
109
-                            sealSignRecord.setSignFlowStatus(3);
110
-                            sealSignRecord.setFileDownloadUrl(fileDownloadUrl.substring(1,fileDownloadUrl.length()-1));
111
-                            sealSignRecordMapper.updataSealSignRecord(sealSignRecord);
112
-                            String filearbitraUrl  = fileDownloadUrl.substring(1,fileDownloadUrl.length()-1);
113
-                            caseApplication.setFilearbitraUrl(filearbitraUrl);
114
-                            caseApplicationMapper.submitCaseApplication(caseApplication);
115
-
98
+                    if(caseApplicationselect!=null){
99
+                        if((caseApplicationselect.getCaseStatus()!=null)&&(caseApplicationselect.getCaseStatus().intValue()==CaseApplicationConstants.ARBITRATED_SEAL)){
100
+                            caseApplication.setCaseStatus(CaseApplicationConstants.ARBITRATION_DELIVERY);
101
+                            //下载审核完成的裁决书,
102
+                            String signFlowId = sealSignRecord.getSignFlowid();
103
+                            EsignHttpResponse fileDownload = SaaSAPIFileUtils.fileDownloadUrl(signFlowId);
104
+                            JsonObject fileDownloadJsonObject = gson.fromJson(fileDownload.getBody(),JsonObject.class);
105
+                            JsonObject fileDownloadData = fileDownloadJsonObject.getAsJsonObject("data");
106
+                            JsonArray filesArray = fileDownloadData.get("files").getAsJsonArray();
107
+                            if(filesArray!=null&&filesArray.size()>0){
108
+                                JsonObject fileObject = (JsonObject)filesArray.get(0);
109
+                                String fileDownloadUrl = fileObject.get("downloadUrl").toString();
110
+                                //修改"签署用印记录表"的状态为签署完成
111
+                                sealSignRecord.setSignFlowStatus(3);
112
+                                sealSignRecord.setFileDownloadUrl(fileDownloadUrl.substring(1,fileDownloadUrl.length()-1));
113
+                                sealSignRecordMapper.updataSealSignRecord(sealSignRecord);
114
+                                String filearbitraUrl  = fileDownloadUrl.substring(1,fileDownloadUrl.length()-1);
115
+                                caseApplication.setFilearbitraUrl(filearbitraUrl);
116
+                                caseApplicationMapper.submitCaseApplication(caseApplication);
117
+
118
+                            }
116
                         }
119
                         }
117
                     }
120
                     }
121
+
118
                 }
122
                 }
119
             }
123
             }
120
 
124
 

+ 3
- 2
ruoyi-system/src/main/resources/mapper/system/SysDeptMapper.xml Zobrazit soubor

9
 		<result property="parentId"   column="parent_id"   />
9
 		<result property="parentId"   column="parent_id"   />
10
 		<result property="ancestors"  column="ancestors"   />
10
 		<result property="ancestors"  column="ancestors"   />
11
 		<result property="deptName"   column="dept_name"   />
11
 		<result property="deptName"   column="dept_name"   />
12
+		<result property="deptType"   column="dept_type"   />
12
 		<result property="orderNum"   column="order_num"   />
13
 		<result property="orderNum"   column="order_num"   />
13
 		<result property="leader"     column="leader"      />
14
 		<result property="leader"     column="leader"      />
14
 		<result property="phone"      column="phone"       />
15
 		<result property="phone"      column="phone"       />
23
 	</resultMap>
24
 	</resultMap>
24
 	
25
 	
25
 	<sql id="selectDeptVo">
26
 	<sql id="selectDeptVo">
26
-        select d.dept_id, d.parent_id, d.ancestors, d.dept_name, d.order_num, d.leader, d.phone, d.email, d.status, d.del_flag, d.create_by, d.create_time 
27
+        select d.dept_id, d.parent_id, d.ancestors, d.dept_name, d.dept_type,d.order_num, d.leader, d.phone, d.email, d.status, d.del_flag, d.create_by, d.create_time
27
         from sys_dept d
28
         from sys_dept d
28
     </sql>
29
     </sql>
29
     
30
     
59
 	</select>
60
 	</select>
60
     
61
     
61
     <select id="selectDeptById" parameterType="Long" resultMap="SysDeptResult">
62
     <select id="selectDeptById" parameterType="Long" resultMap="SysDeptResult">
62
-		select d.dept_id, d.parent_id, d.ancestors, d.dept_name, d.order_num, d.leader, d.phone, d.email, d.status,
63
+		select d.dept_id, d.parent_id, d.ancestors, d.dept_name,d.dept_type, d.order_num, d.leader, d.phone, d.email, d.status,
63
 			(select dept_name from sys_dept where dept_id = d.parent_id) parent_name
64
 			(select dept_name from sys_dept where dept_id = d.parent_id) parent_name
64
 		from sys_dept d
65
 		from sys_dept d
65
 		where d.dept_id = #{deptId}
66
 		where d.dept_id = #{deptId}

+ 1
- 0
ruoyi-system/src/main/resources/mapper/wisdomarbitrate/CaseAffiliateMapper.xml Zobrazit soubor

97
         contact_telphone_agent = #{contactTelphoneAgent},
97
         contact_telphone_agent = #{contactTelphoneAgent},
98
         contact_address_agent = #{contactAddressAgent},
98
         contact_address_agent = #{contactAddressAgent},
99
         send_email = #{sendEmail},
99
         send_email = #{sendEmail},
100
+        residen_affili = #{residenAffili},
100
         track_num = #{trackNum}
101
         track_num = #{trackNum}
101
 
102
 
102
         where id = #{id}
103
         where id = #{id}

+ 3
- 0
ruoyi-system/src/main/resources/mapper/wisdomarbitrate/CaseApplicationMapper.xml Zobrazit soubor

402
         <if test="properPreser != null ">proper_preser,</if>
402
         <if test="properPreser != null ">proper_preser,</if>
403
 
403
 
404
         <if test="createBy != null  and createBy != ''">create_by,</if>
404
         <if test="createBy != null  and createBy != ''">create_by,</if>
405
+        <if test="importFlag != null ">import_flag,</if>
405
         create_time
406
         create_time
406
         )values(
407
         )values(
407
         <if test="caseNum != null and caseNum != ''">#{caseNum},</if>
408
         <if test="caseNum != null and caseNum != ''">#{caseNum},</if>
428
         <if test="properPreser != null ">#{properPreser},</if>
429
         <if test="properPreser != null ">#{properPreser},</if>
429
 
430
 
430
         <if test="createBy != null  and createBy != ''">#{createBy},</if>
431
         <if test="createBy != null  and createBy != ''">#{createBy},</if>
432
+        <if test="importFlag != null ">#{importFlag},</if>
431
         sysdate()
433
         sysdate()
432
         )
434
         )
433
     </insert>
435
     </insert>
456
             <if test="caseDescribe != null  and caseDescribe != ''">case_describe = #{caseDescribe},</if>
458
             <if test="caseDescribe != null  and caseDescribe != ''">case_describe = #{caseDescribe},</if>
457
             <if test="caseResult != null  and caseResult != ''">case_result = #{caseResult},</if>
459
             <if test="caseResult != null  and caseResult != ''">case_result = #{caseResult},</if>
458
             <if test="caseStatus != null">case_status = #{caseStatus},</if>
460
             <if test="caseStatus != null">case_status = #{caseStatus},</if>
461
+            <if test="properPreser != null">proper_preser = #{properPreser},</if>
459
 
462
 
460
             <if test="updateBy != null  and updateBy != ''">update_by = #{updateBy},</if>
463
             <if test="updateBy != null  and updateBy != ''">update_by = #{updateBy},</if>
461
             <if test="caseNum != null and caseNum != ''">case_num = #{caseNum},</if>
464
             <if test="caseNum != null and caseNum != ''">case_num = #{caseNum},</if>