18792927508 преди 2 години
родител
ревизия
078c214202
променени са 1 файла, в които са добавени 31 реда и са изтрити 6 реда
  1. 31
    6
      ruoyi-system/src/main/java/com/ruoyi/wisdomarbitrate/service/impl/AdjudicationServiceImpl.java

+ 31
- 6
ruoyi-system/src/main/java/com/ruoyi/wisdomarbitrate/service/impl/AdjudicationServiceImpl.java Целия файл

@@ -176,7 +176,6 @@ public class AdjudicationServiceImpl implements IAdjudicationService {
176 176
                 Map<String, String> columnValueMap = columnValueList.stream().collect(Collectors.toMap(ColumnValue::getColumn, ColumnValue::getValue));
177 177
                 agentName=columnValueMap.get("agentName");
178 178
                 resName=columnValueMap.get("respondentName");
179
-                resName=columnValueMap.get("respondentName");
180 179
                 // 懒得if,暂时这样
181 180
                 //
182 181
                 for (String bookmark : bookmarkList) {
@@ -188,7 +187,28 @@ public class AdjudicationServiceImpl implements IAdjudicationService {
188 187
                             } else {
189 188
                                 datas.put(bookmark, "女");
190 189
                             }
191
-                        }else {
190
+                        }else if(bookmark.equals("arbitratClaims")){
191
+                            // 请求仲裁庭裁决
192
+                            String arbitratClaims = columnValueMap.get(bookmark);
193
+                            if(StrUtil.isNotEmpty(arbitratClaims)){
194
+                                String replace = arbitratClaims.replace("甲方", "被申请人").replace("乙方", "申请人");
195
+                                datas.put("arbitratClaims", replace);
196
+
197
+                            }else {
198
+                                datas.put("arbitratClaims", "");
199
+                            }
200
+                        }else if(bookmark.equals("mediationAgreement")){
201
+                            // 查询本案事实如下
202
+                            String mediationAgreement = columnValueMap.get(bookmark);
203
+                            if(StrUtil.isNotEmpty(mediationAgreement)){
204
+                                String replace = mediationAgreement.replace("甲方", "被申请人").replace("乙方", "申请人");
205
+                                datas.put("mediationAgreement", replace);
206
+
207
+                            }else {
208
+                                datas.put("mediationAgreement", "");
209
+                            }
210
+                        }
211
+                        else {
192 212
                             datas.put(bookmark, columnValueMap.get(bookmark));
193 213
                         }
194 214
                     }
@@ -196,6 +216,7 @@ public class AdjudicationServiceImpl implements IAdjudicationService {
196 216
             }else {
197 217
 
198 218
             }
219
+
199 220
             // 裁决书生成时间
200 221
             LocalDate now = LocalDate.now();
201 222
             String year = Integer.toString(now.getYear());
@@ -204,6 +225,8 @@ public class AdjudicationServiceImpl implements IAdjudicationService {
204 225
             String equipmentNo = getNewEquipmentNo();
205 226
             // 裁决书编号
206 227
             datas.put("num", equipmentNo);
228
+            // 仲裁费
229
+            datas.put("arbitrationFee", caseApplicationById.getFeePayable().toString());
207 230
             // 案件创建时间
208 231
             Date createTime = caseApplicationById.getCreateTime();
209 232
             SimpleDateFormat sdf = new SimpleDateFormat("yyyy年MM月dd日");
@@ -243,8 +266,9 @@ public class AdjudicationServiceImpl implements IAdjudicationService {
243 266
                     attendName += "被申请人" + resName;
244 267
                 }
245 268
                 if(attendName.endsWith("、")){
246
-                    agentName=attendName.replace("、","");
269
+                    attendName=attendName.replace("、","");
247 270
                 }
271
+                datas.put("attendName", attendName);
248 272
             }
249 273
 
250 274
             // 仲裁员名称
@@ -297,7 +321,7 @@ public class AdjudicationServiceImpl implements IAdjudicationService {
297 321
                 } else {
298 322
                     // 出席
299 323
                     String attendReplace = attend.replace("{{agentName}}", Optional.ofNullable(agentName).orElse(""));
300
-                    datas.put("attend",attend);
324
+                    datas.put("attend",attendReplace);
301 325
                     // 被申请人证据
302 326
                     if(caseAttachMap!=null && CollectionUtil.isNotEmpty(caseAttachMap.get(6))){
303 327
                        // 开庭+出席+被申提供证据
@@ -310,7 +334,7 @@ public class AdjudicationServiceImpl implements IAdjudicationService {
310 334
                             for (CaseAttach caseAttach : caseAttaches) {
311 335
                                 stringBuilder.append(caseAttach.getAnnexName()).append("\n");
312 336
                             }
313
-                            resFileRplace = resFile.replace("{{resFile}}", stringBuilder.toString()).replace("{{applicantOpinion}}", Optional.ofNullable(arbitrateRecordSelect.getApplicantOpinion()).orElse(""));
337
+                            resFileRplace = resFile.replace("{{resFile}}", stringBuilder.toString()).replace("{{applicantOpinion}}", (arbitrateRecordSelect==null||arbitrateRecordSelect.getApplicantOpinion()==null?"":arbitrateRecordSelect.getApplicantOpinion()));
314 338
                         }
315 339
                         datas.put("resFile",resFileRplace);
316 340
                     }else {
@@ -325,7 +349,7 @@ public class AdjudicationServiceImpl implements IAdjudicationService {
325 349
                         for (CaseAttach caseAttach : caseAttaches) {
326 350
                             stringBuilder.append(caseAttach.getAnnexName()).append("\n");
327 351
                         }
328
-                         resAttendOpinionReplace = resAttendOpinion.replace("{{applicantFile}}", stringBuilder.toString()).replace("{{respondentOpinion}}", arbitrateRecordSelect.getRespondentOpinion()==null?"":arbitrateRecordSelect.getRespondentOpinion());
352
+                         resAttendOpinionReplace = resAttendOpinion.replace("{{applicantFile}}", stringBuilder.toString()).replace("{{respondentOpinion}}", (arbitrateRecordSelect==null||arbitrateRecordSelect.getRespondentOpinion()==null)?"":arbitrateRecordSelect.getRespondentOpinion());
329 353
                     }
330 354
 
331 355
                     datas.put("resAttendOpinion",resAttendOpinionReplace);
@@ -333,6 +357,7 @@ public class AdjudicationServiceImpl implements IAdjudicationService {
333 357
             }
334 358
 
335 359
 
360
+
336 361
             String month = String.format("%02d", now.getMonthValue());
337 362
             String day = String.format("%02d", now.getDayOfMonth());
338 363
             // todo