From ad4f1aecb2a4bf682b706988bb2bb3725b0f680c Mon Sep 17 00:00:00 2001 From: 18792927508 <1322446236@qq.com> Date: Wed, 18 Oct 2023 10:19:49 +0800 Subject: [PATCH 1/9] =?UTF-8?q?=E8=A7=92=E8=89=B2=E6=A1=88=E4=BB=B6?= =?UTF-8?q?=E6=9F=A5=E8=AF=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../mapper/wisdomarbitrate/CaseApplicationMapper.xml | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/ruoyi-system/src/main/resources/mapper/wisdomarbitrate/CaseApplicationMapper.xml b/ruoyi-system/src/main/resources/mapper/wisdomarbitrate/CaseApplicationMapper.xml index 0991056..51246c9 100644 --- a/ruoyi-system/src/main/resources/mapper/wisdomarbitrate/CaseApplicationMapper.xml +++ b/ruoyi-system/src/main/resources/mapper/wisdomarbitrate/CaseApplicationMapper.xml @@ -128,8 +128,7 @@ - or(t.identity_type=1 and t.case_status =#{financeStatus}) - + or ( t.identity_type=1 and t.case_status =#{financeStatus}) ) t1 @@ -219,9 +218,9 @@ ) - - or( t.identity_type=1 and t.case_status =#{financeStatus}) + + or ( t.identity_type=1 and t.case_status =#{financeStatus}) ) t1 From 10f7fffe10b81f54b6099658a8128cf281615912 Mon Sep 17 00:00:00 2001 From: 18792927508 <1322446236@qq.com> Date: Wed, 18 Oct 2023 18:04:31 +0800 Subject: [PATCH 2/9] =?UTF-8?q?=E5=90=88=E5=B9=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../wisdomarbitrate/CaseApplicationMapper.xml | 121 +++++++++--------- 1 file changed, 61 insertions(+), 60 deletions(-) diff --git a/ruoyi-system/src/main/resources/mapper/wisdomarbitrate/CaseApplicationMapper.xml b/ruoyi-system/src/main/resources/mapper/wisdomarbitrate/CaseApplicationMapper.xml index 51246c9..b5fb734 100644 --- a/ruoyi-system/src/main/resources/mapper/wisdomarbitrate/CaseApplicationMapper.xml +++ b/ruoyi-system/src/main/resources/mapper/wisdomarbitrate/CaseApplicationMapper.xml @@ -49,7 +49,7 @@ select c.id ,c.case_num ,c.case_subject_amount ,c.register_date ,c.arbitrat_method , CASE c.arbitrat_method when 1 then '开庭审理' when 2 then '书面审理' - ELSE '无审理方式' - END arbitratMethodName, + ELSE '无审理方式' + END arbitratMethodName, c.case_status , CASE c.case_status when 0 then '立案申请' when 1 then '待立案审查' when 2 then '待缴费' when 3 then '待缴费确认' when 4 then '待案件质证' when 5 then '待组庭审核' @@ -586,30 +587,30 @@ - \ No newline at end of file + From 7980d2880de90e4f45c5268599143c05bd59045a Mon Sep 17 00:00:00 2001 From: 18792927508 <1322446236@qq.com> Date: Wed, 18 Oct 2023 18:19:14 +0800 Subject: [PATCH 3/9] =?UTF-8?q?=E4=BB=A3=E7=A0=81=E5=86=B2=E7=AA=81?= =?UTF-8?q?=E8=A7=A3=E5=86=B3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../mapper/CaseApplicationMapper.java | 7 - .../impl/CaseApplicationServiceImpl.java | 168 +++++++++--------- .../wisdomarbitrate/CaseApplicationMapper.xml | 117 +----------- 3 files changed, 85 insertions(+), 207 deletions(-) diff --git a/ruoyi-system/src/main/java/com/ruoyi/wisdomarbitrate/mapper/CaseApplicationMapper.java b/ruoyi-system/src/main/java/com/ruoyi/wisdomarbitrate/mapper/CaseApplicationMapper.java index 3a3cf75..b2a5ff9 100644 --- a/ruoyi-system/src/main/java/com/ruoyi/wisdomarbitrate/mapper/CaseApplicationMapper.java +++ b/ruoyi-system/src/main/java/com/ruoyi/wisdomarbitrate/mapper/CaseApplicationMapper.java @@ -55,16 +55,9 @@ public interface CaseApplicationMapper { */ void updatePayType(CaseConfirmPayDTO payDTO); - /** - * 查询部门长案件 - * @param caseApplication - * @return - */ - List selectDeptHeadCaseApplicationList(@Param("caseApplication") CaseApplication caseApplication, @Param("statusList")List caseStatusList); ToDoCount selectAdminCaseToDoCount(); - ToDoCount selectDeptHeadCaseToDoCount( @Param("statusList")List caseStatusList); ToDoCount selectTodoCountByRole(CaseApplication caseApplication); } diff --git a/ruoyi-system/src/main/java/com/ruoyi/wisdomarbitrate/service/impl/CaseApplicationServiceImpl.java b/ruoyi-system/src/main/java/com/ruoyi/wisdomarbitrate/service/impl/CaseApplicationServiceImpl.java index 26e4836..eca8ee5 100644 --- a/ruoyi-system/src/main/java/com/ruoyi/wisdomarbitrate/service/impl/CaseApplicationServiceImpl.java +++ b/ruoyi-system/src/main/java/com/ruoyi/wisdomarbitrate/service/impl/CaseApplicationServiceImpl.java @@ -243,12 +243,12 @@ public class CaseApplicationServiceImpl implements ICaseApplicationService { List caseAffiliates = caseApplication.getCaseAffiliates(); Map deptMap =new HashMap<>(); if (caseAffiliates != null && caseAffiliates.size() > 0) { - // 查询所有的组织机构,组装成map - List deptList = sysDeptMapper.selectDeptList(new SysDept()); - if (CollectionUtil.isEmpty(deptList)) { - deptList = new ArrayList<>(); - } - deptMap = deptList.stream().collect(Collectors.toMap(SysDept::getDeptName, SysDept::getDeptId,(oldV,newV)->newV)); + // 查询所有的组织机构,组装成map + List deptList = sysDeptMapper.selectDeptList(new SysDept()); + if (CollectionUtil.isEmpty(deptList)) { + deptList = new ArrayList<>(); + } + deptMap = deptList.stream().collect(Collectors.toMap(SysDept::getDeptName, SysDept::getDeptId,(oldV,newV)->newV)); for (CaseAffiliate caseAffiliate : caseAffiliates) { caseAffiliate.setCaseAppliId(caseApplication.getId()); @@ -307,7 +307,7 @@ public class CaseApplicationServiceImpl implements ICaseApplicationService { String currentDay = DateUtils.dateTime(); String caseNum = "zc"+ currentDay; //查询出当天的案件编号的最大值 - Integer maxCaseNum = caseApplicationMapper.selectCaseNumLike(caseNum,caseNum.length()); + Integer maxCaseNum = caseApplicationMapper.selectCaseNumLike(caseNum,caseNum.length()); if(null == maxCaseNum){ caseNum = caseNum + "001"; }else { @@ -373,7 +373,7 @@ public class CaseApplicationServiceImpl implements ICaseApplicationService { } - caseAffiliateMapper.updataCaseAffiliate(caseAffiliate); + caseAffiliateMapper.updataCaseAffiliate(caseAffiliate); } } @@ -428,7 +428,7 @@ public class CaseApplicationServiceImpl implements ICaseApplicationService { SmsUtils.sendSms(request); } } else if (null != agentUser.getDeptId() && !String.valueOf(agentUser.getDeptId()).equals(caseAffiliate.getApplicationOrganId())) { - return "申请机构与申请代理人不匹配"; + return "申请机构与申请代理人不匹配"; } else if (null != agentUser.getDeptId() && String.valueOf(agentUser.getDeptId()).equals(caseAffiliate.getApplicationOrganId())){ // 同步用户表和案件关联人表的手机号和名称 caseAffiliate.setContactTelphoneAgent(agentUser.getPhonenumber()); @@ -602,47 +602,47 @@ public class CaseApplicationServiceImpl implements ICaseApplicationService { //对不重复的立案对象集合的立案对象重新组装对应的案件关联人信息 // if(caseApplicationListinsertDiffer!=null&&caseApplicationListinsertDiffer.size()>0){ - List caseApplicationNewList = null; - for (int i = 0; i < caseApplicationListinsert.size(); i++){ - caseApplicationNewList = new ArrayList<>(); - CaseApplication caseApplicationinsertDiffer = caseApplicationListinsert.get(i); - // 设置自动编码 - caseApplicationinsertDiffer.setCaseNum(generateCaseNum()); - List caseAffiliatesnew = new ArrayList<>(); - CaseApplication caseApplicationNew = new CaseApplication(); - copyCaseApplication(caseApplicationinsertDiffer,caseApplicationNew); - if(caseApplicationListinsert!=null&&caseApplicationListinsert.size()>0){ - for (int j = 0; j < caseApplicationListinsert.size(); j++){ - CaseApplication caseApplicationinsert = caseApplicationListinsert.get(j); + List caseApplicationNewList = null; + for (int i = 0; i < caseApplicationListinsert.size(); i++){ + caseApplicationNewList = new ArrayList<>(); + CaseApplication caseApplicationinsertDiffer = caseApplicationListinsert.get(i); + // 设置自动编码 + caseApplicationinsertDiffer.setCaseNum(generateCaseNum()); + List caseAffiliatesnew = new ArrayList<>(); + CaseApplication caseApplicationNew = new CaseApplication(); + copyCaseApplication(caseApplicationinsertDiffer,caseApplicationNew); + if(caseApplicationListinsert!=null&&caseApplicationListinsert.size()>0){ + for (int j = 0; j < caseApplicationListinsert.size(); j++){ + CaseApplication caseApplicationinsert = caseApplicationListinsert.get(j); - if(StringUtils.isNotEmpty(caseApplicationinsert.getCaseNum())&& - caseApplicationinsert.getCaseNum().equals(caseApplicationinsertDiffer.getCaseNum())){ + if(StringUtils.isNotEmpty(caseApplicationinsert.getCaseNum())&& + caseApplicationinsert.getCaseNum().equals(caseApplicationinsertDiffer.getCaseNum())){ - caseAffiliatesnew.addAll(caseApplicationinsert.getCaseAffiliates()); - } + caseAffiliatesnew.addAll(caseApplicationinsert.getCaseAffiliates()); } - caseApplicationNew.setCaseAffiliates(caseAffiliatesnew); - caseApplicationNewList.add(caseApplicationNew); + } + caseApplicationNew.setCaseAffiliates(caseAffiliatesnew); + caseApplicationNewList.add(caseApplicationNew); + } + + for (int k = 0; k < caseApplicationNewList.size(); k++){ + CaseApplication caseApplicationItera = caseApplicationNewList.get(k); + // 新增立案信息 + caseApplicationItera.setCaseStatus(CaseApplicationConstants.CASE_APPLICATION); + caseApplicationItera.setCreateBy(getUsername()); + int rows = caseApplicationMapper.insertCaseApplication(caseApplicationItera); + List caseAffiliates = caseApplicationItera.getCaseAffiliates(); + if(caseAffiliates!=null&&caseAffiliates.size()>0){ + for (CaseAffiliate caseAffiliate : caseAffiliates){ + caseAffiliate.setCaseAppliId(caseApplicationItera.getId()); + + } + caseAffiliateMapper.batchCaseAffiliate(caseAffiliates); } - for (int k = 0; k < caseApplicationNewList.size(); k++){ - CaseApplication caseApplicationItera = caseApplicationNewList.get(k); - // 新增立案信息 - caseApplicationItera.setCaseStatus(CaseApplicationConstants.CASE_APPLICATION); - caseApplicationItera.setCreateBy(getUsername()); - int rows = caseApplicationMapper.insertCaseApplication(caseApplicationItera); - List caseAffiliates = caseApplicationItera.getCaseAffiliates(); - if(caseAffiliates!=null&&caseAffiliates.size()>0){ - for (CaseAffiliate caseAffiliate : caseAffiliates){ - caseAffiliate.setCaseAppliId(caseApplicationItera.getId()); - - } - caseAffiliateMapper.batchCaseAffiliate(caseAffiliates); - } - - successNum++; - successMsg.append("
" + successNum + "、立案编号 " + caseApplicationItera.getCaseNum() + " 导入成功"); - } + successNum++; + successMsg.append("
" + successNum + "、立案编号 " + caseApplicationItera.getCaseNum() + " 导入成功"); + } // } @@ -653,7 +653,7 @@ public class CaseApplicationServiceImpl implements ICaseApplicationService { }else { throw new ServiceException("导入立案申请数据不能为空!"); } - return successMsg.append(failureMsg.toString()).toString(); + return successMsg.append(failureMsg.toString()).toString(); } @@ -1019,7 +1019,7 @@ public class CaseApplicationServiceImpl implements ICaseApplicationService { JSONObject coordinateObj = coordinatesArray.getJSONObject(0); double positionX = coordinateObj.getDoubleValue("positionX"); double positionY = coordinateObj.getDoubleValue("positionY"); - sealSignRecord.setPositionXpsn(positionX); + sealSignRecord.setPositionXpsn(positionX+90); sealSignRecord.setPositionYpsn(positionY); } }else { @@ -1034,8 +1034,8 @@ public class CaseApplicationServiceImpl implements ICaseApplicationService { JSONObject coordinateObj = coordinatesArray.getJSONObject(0); double positionX = coordinateObj.getDoubleValue("positionX"); double positionY = coordinateObj.getDoubleValue("positionY"); - sealSignRecord.setPositionXorg(positionX); - sealSignRecord.setPositionYorg(positionY); + sealSignRecord.setPositionXorg(positionX-10); + sealSignRecord.setPositionYorg(positionY+10); } } } @@ -1423,19 +1423,19 @@ public class CaseApplicationServiceImpl implements ICaseApplicationService { for(int i = 0;i < idStrList.length;i ++ ){ idList.add(Long.parseLong(idStrList[i])); } - // 查询仲裁员电话号 - List userList= sysUserMapper.selectUserListByIds(idList); - if(CollectionUtil.isNotEmpty(userList)) { - for (SysUser user : userList) { - //给仲裁员发送短信通知 - request.setPhone(user.getPhonenumber()); - // 1947342 普通短信 开庭日期通知 尊敬的{1}用户,您的{2}仲裁案件,开庭日期已确定为{3},请知晓,如非本人操作,请忽略本短信。 - String name = user.getNickName(); - request.setTemplateParamSet(new String[]{name, caseNum, hearDatestr}); - SmsUtils.sendSms(request); + // 查询仲裁员电话号 + List userList= sysUserMapper.selectUserListByIds(idList); + if(CollectionUtil.isNotEmpty(userList)) { + for (SysUser user : userList) { + //给仲裁员发送短信通知 + request.setPhone(user.getPhonenumber()); + // 1947342 普通短信 开庭日期通知 尊敬的{1}用户,您的{2}仲裁案件,开庭日期已确定为{3},请知晓,如非本人操作,请忽略本短信。 + String name = user.getNickName(); + request.setTemplateParamSet(new String[]{name, caseNum, hearDatestr}); + SmsUtils.sendSms(request); - } - } + } + } } @@ -1448,7 +1448,7 @@ public class CaseApplicationServiceImpl implements ICaseApplicationService { CaseAffiliate caseAffiliateselect = caseAffiliatListeselect.get(j); int identityType = caseAffiliateselect.getIdentityType(); if(identityType==1){ - caseAffiliateselect.setName(caseAffiliateselect.getApplicationOrganName()); + caseAffiliateselect.setName(caseAffiliateselect.getApplicationOrganName()); } //给申请人、被申请人发送短信通知 @@ -1501,7 +1501,7 @@ public class CaseApplicationServiceImpl implements ICaseApplicationService { private void assignmentCaseAffiliates(CaseApplication caseApplication, List caseAffiliatesnew, Map deptMap) { - // 申请人信息 + // 申请人信息 CaseAffiliate caseAffiliate = new CaseAffiliate(); // BeanUtils.copyBeanProp(caseApplication,caseAffiliate); @@ -1516,7 +1516,7 @@ public class CaseApplicationServiceImpl implements ICaseApplicationService { if(StrUtil.isNotEmpty(s)){ StringBuilder errorMsg = caseApplication.getErrorMsg(); if(StrUtil.isEmpty(errorMsg)){ - errorMsg=new StringBuilder(); + errorMsg=new StringBuilder(); } errorMsg.append(s); caseApplication.setErrorMsg(errorMsg); @@ -1563,27 +1563,27 @@ public class CaseApplicationServiceImpl implements ICaseApplicationService { - // 将组织机构id设为申请人名称 - if(deptMap.containsKey(caseApplication.getName())){ - caseAffiliate.setApplicationOrganId(String.valueOf(deptMap.get(caseApplication.getName()))); - caseAffiliate.setApplicationOrganName(caseApplication.getName()); - }else { - // 如果不存在则新增 - SysDept dept = new SysDept(); - dept.setParentId(0L); - dept.setDeptName(caseApplication.getName()); - dept.setAncestors("0"); - dept.setOrderNum(1); - dept.setStatus("0"); - dept.setDelFlag("0"); - dept.setCreateBy(getUsername()); - dept.setUpdateBy(getUsername()); - sysDeptMapper.insertDept(dept); - deptMap.put(dept.getDeptName(),dept.getDeptId()); - caseAffiliate.setApplicationOrganId(String.valueOf(dept.getDeptId())); - caseAffiliate.setApplicationOrganName(caseApplication.getName()); + // 将组织机构id设为申请人名称 + if(deptMap.containsKey(caseApplication.getName())){ + caseAffiliate.setApplicationOrganId(String.valueOf(deptMap.get(caseApplication.getName()))); + caseAffiliate.setApplicationOrganName(caseApplication.getName()); + }else { + // 如果不存在则新增 + SysDept dept = new SysDept(); + dept.setParentId(0L); + dept.setDeptName(caseApplication.getName()); + dept.setAncestors("0"); + dept.setOrderNum(1); + dept.setStatus("0"); + dept.setDelFlag("0"); + dept.setCreateBy(getUsername()); + dept.setUpdateBy(getUsername()); + sysDeptMapper.insertDept(dept); + deptMap.put(dept.getDeptName(),dept.getDeptId()); + caseAffiliate.setApplicationOrganId(String.valueOf(dept.getDeptId())); + caseAffiliate.setApplicationOrganName(caseApplication.getName()); - } + } } diff --git a/ruoyi-system/src/main/resources/mapper/wisdomarbitrate/CaseApplicationMapper.xml b/ruoyi-system/src/main/resources/mapper/wisdomarbitrate/CaseApplicationMapper.xml index 3d5c900..6c8ed3a 100644 --- a/ruoyi-system/src/main/resources/mapper/wisdomarbitrate/CaseApplicationMapper.xml +++ b/ruoyi-system/src/main/resources/mapper/wisdomarbitrate/CaseApplicationMapper.xml @@ -134,14 +134,7 @@
) t1 - - - - - - - - + order by t1.create_time desc,t1.case_num desc - - diff --git a/ruoyi-system/src/main/resources/mapper/wisdomarbitrate/CaseAttachMapper.xml b/ruoyi-system/src/main/resources/mapper/wisdomarbitrate/CaseAttachMapper.xml index 2eabbbd..d68b234 100644 --- a/ruoyi-system/src/main/resources/mapper/wisdomarbitrate/CaseAttachMapper.xml +++ b/ruoyi-system/src/main/resources/mapper/wisdomarbitrate/CaseAttachMapper.xml @@ -17,6 +17,13 @@ INSERT INTO case_attach (case_appli_id, annex_name, annex_path , annex_type,note,use_id,use_account) VALUES (#{caseAppliId}, #{annexName}, #{annexPath},#{annexType},#{note},#{userId},#{userName}) + + delete from case_attach + where annex_id in + + #{id} + +