印章审核回调 #128

Merged
qtz merged 2 commits from qtz1 into dev 2024-03-20 01:18:48 +00:00
7 changed files with 72 additions and 32 deletions
Showing only changes of commit c54981e584 - Show all commits
@@ -1,19 +1,6 @@
package com.ruoyi.web.controller.system; package com.ruoyi.web.controller.system;
import java.util.ArrayList; import com.ruoyi.common.annotation.Anonymous;
import java.util.List;
import javax.servlet.http.HttpServletResponse;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.security.access.prepost.PreAuthorize;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.DeleteMapping;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.PutMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import com.ruoyi.common.annotation.Log; import com.ruoyi.common.annotation.Log;
import com.ruoyi.common.core.controller.BaseController; import com.ruoyi.common.core.controller.BaseController;
import com.ruoyi.common.core.domain.AjaxResult; import com.ruoyi.common.core.domain.AjaxResult;
@@ -24,6 +11,14 @@ import com.ruoyi.common.utils.StringUtils;
import com.ruoyi.common.utils.poi.ExcelUtil; import com.ruoyi.common.utils.poi.ExcelUtil;
import com.ruoyi.system.service.ISysDictDataService; import com.ruoyi.system.service.ISysDictDataService;
import com.ruoyi.system.service.ISysDictTypeService; import com.ruoyi.system.service.ISysDictTypeService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.security.access.prepost.PreAuthorize;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.*;
import javax.servlet.http.HttpServletResponse;
import java.util.ArrayList;
import java.util.List;
/** /**
* 数据字典信息 * 数据字典信息
@@ -82,6 +77,20 @@ public class SysDictDataController extends BaseController
} }
return success(data); return success(data);
} }
/**
* 根据字典类型查询字典数据信息,跳过token
*/
@Anonymous
@GetMapping(value = "/type/skipToken/{dictType}")
public AjaxResult skipToken(@PathVariable String dictType)
{
List<SysDictData> data = dictTypeService.selectDictDataByType(dictType);
if (StringUtils.isNull(data))
{
data = new ArrayList<SysDictData>();
}
return success(data);
}
/** /**
* 新增字典类型 * 新增字典类型
@@ -73,6 +73,7 @@ public class MsCaseApplicationController extends BaseController {
/** /**
* 新增案件 * 新增案件
*/ */
// todo 重复提交校验
@PostMapping("/insert") @PostMapping("/insert")
public AjaxResult insert(@RequestBody MsCaseApplicationVO caseApplication ) public AjaxResult insert(@RequestBody MsCaseApplicationVO caseApplication )
{ {
@@ -18,7 +18,7 @@ ruoyi:
# 开发环境配置 # 开发环境配置
server: server:
# 测试环境6001,开发环境7001 # 测试环境6001,开发环境7001
port: 6001 port: 7001
servlet: servlet:
# 应用的访问路径 # 应用的访问路径
context-path: / context-path: /
@@ -193,7 +193,7 @@ arbitrateConfig:
url: http://121.40.189.20:9001/callArbitrateCaseApplication/generateCaseApplication url: http://121.40.189.20:9001/callArbitrateCaseApplication/generateCaseApplication
# 回调通知 # 回调通知
signSealCallbackConfig: signSealCallbackConfig:
url: http://121.40.189.20:6001/mssignSeal/signSeaalCaseApplicaCallback url: http://121.40.189.20:7001/mssignSeal/signSeaalCaseApplicaCallback
# onlyOffice系统url配置 # onlyOffice系统url配置
onlyOfficeConfig: onlyOfficeConfig:
# url: http://172.16.0.254:9090/files/upload # url: http://172.16.0.254:9090/files/upload
@@ -1865,7 +1865,7 @@ public class MsCaseApplicationServiceImpl implements MsCaseApplicationService {
// 申请人预约 // 申请人预约
if (vo.getMiniProgressFlag() == null || vo.getMiniProgressFlag().equals( YesOrNoEnum.NO.getCode())) { if (vo.getMiniProgressFlag() == null || vo.getMiniProgressFlag().equals( YesOrNoEnum.NO.getCode())) {
// 新增日志 // 新增日志
CaseLogUtils.insertCaseLog(vo.getId(), currentFlow.getNodeId(), currentFlow.getCaseStatusName(), "申请人选择调解员"); CaseLogUtils.insertCaseLog(vo.getId(), currentFlow.getNodeId(), currentFlow.getCaseStatusName(), null);
if (StrUtil.isEmpty(msCaseAffiliate.getRespondentIdentityNum())) { if (StrUtil.isEmpty(msCaseAffiliate.getRespondentIdentityNum())) {
return AjaxResult.error("被申请人身份证为空"); return AjaxResult.error("被申请人身份证为空");
@@ -1876,7 +1876,7 @@ public class MsCaseApplicationServiceImpl implements MsCaseApplicationService {
} else { } else {
// 被申请人预约 // 被申请人预约
// 新增日志 // 新增日志
CaseLogUtils.insertCaseLog(vo.getId(), currentFlow.getNodeId(), currentFlow.getCaseStatusName(), "被申请人选择调解员"); CaseLogUtils.insertCaseLog(vo.getId(), currentFlow.getNodeId(), currentFlow.getCaseStatusName(), null);
// 判断申请人是否预约 // 判断申请人是否预约
caseApplicationService. isReservation( vo,userIds); caseApplicationService. isReservation( vo,userIds);
@@ -2225,6 +2225,7 @@ public class MsCaseApplicationServiceImpl implements MsCaseApplicationService {
if (currentFlow == null) { if (currentFlow == null) {
throw new ServiceException("未找到当前流程节点"); throw new ServiceException("未找到当前流程节点");
} }
Integer mediaResult = req.getMediaResult();
MsCaseAffiliate caseAffiliate = msCaseAffiliateMapper.selectByPrimaryKey(req.getId()); MsCaseAffiliate caseAffiliate = msCaseAffiliateMapper.selectByPrimaryKey(req.getId());
if (application.getMediationMethod().equals("1")) { if (application.getMediationMethod().equals("1")) {
// 线上调解 // 线上调解
@@ -2237,9 +2238,7 @@ public class MsCaseApplicationServiceImpl implements MsCaseApplicationService {
msCaseAttachMapper.updateCaseAttach(attach); msCaseAttachMapper.updateCaseAttach(attach);
} }
} }
Integer mediaResult = req.getMediaResult(); if(mediaResult ==1){
if(mediaResult!=null){
if(mediaResult.intValue()==1){
//达成调解 //达成调解
List<MsCaseAttach> caseAttachList = msCaseAttachMapper.queryAnnexPathByCaseId(req.getId()); List<MsCaseAttach> caseAttachList = msCaseAttachMapper.queryAnnexPathByCaseId(req.getId());
if (caseAttachList != null && caseAttachList.size() > 0) { if (caseAttachList != null && caseAttachList.size() > 0) {
@@ -2898,7 +2897,7 @@ public class MsCaseApplicationServiceImpl implements MsCaseApplicationService {
} }
} }
}
} else { } else {
// 线下调解 // 线下调解
List<MsCaseAttach> attachList = req.getAttachList(); List<MsCaseAttach> attachList = req.getAttachList();
@@ -2911,14 +2910,45 @@ public class MsCaseApplicationServiceImpl implements MsCaseApplicationService {
attach.setCaseAppliId(req.getId()); attach.setCaseAppliId(req.getId());
msCaseAttachMapper.updateCaseAttach(attach); msCaseAttachMapper.updateCaseAttach(attach);
} }
// msCaseAttachMapper.batchSave(attachList);
// 修改案件状态为待送达 // 修改案件状态为待送达
Example flowExample = new Example(MsCaseFlow.class); Example flowExample = new Example(MsCaseFlow.class);
flowExample.createCriteria().andEqualTo("caseStatusName", "待送达"); if(mediaResult ==1 || mediaResult == 5){
// 达成调解,达成和解,案件状态改为待送达
flowExample.createCriteria().andEqualTo("caseStatusName", "待送达");
} else if(mediaResult == 2 || mediaResult == 3){
// 未达成调解,未达成调解但不在争议改为结束状态
flowExample.createCriteria().andEqualTo("caseStatusName", "结束");
}
else if(mediaResult == 4){
// 未达成调解但同意引入仲裁系统,改为结束状态,并调仲裁新增接口
flowExample.createCriteria().andEqualTo("caseStatusName", "结束");
String accessSec = "mCFMA6ffe938v79m";
MsCaseApplicationVO applicationVO = new MsCaseApplicationVO();
BeanUtils.copyProperties(application,applicationVO);
CaseApplicationVO caseApplicationVO = new CaseApplicationVO();
BeanUtils.copyProperties(applicationVO,caseApplicationVO);
boolean importFlag = applicationVO.isImportFlag();
if(importFlag==true){
caseApplicationVO.setImportFlag(1);
}else {
caseApplicationVO.setImportFlag(0);
}
String paramsbody = JSONUtil.toJsonStr(caseApplicationVO);
long timestamp = System.currentTimeMillis();
String signStr = SignCheckUtils.getSign(paramsbody, accessSec, timestamp);
String urlstr = arbitrateUrl;
HttpResponse httpResponse = HttpRequest.post(urlstr)
.header("timestampstr", String.valueOf(timestamp))
.header("signstr", signStr)
.body(paramsbody)
.execute();
}
MsCaseFlow caseFlow = caseFlowMapper.selectOneByExample(flowExample); MsCaseFlow caseFlow = caseFlowMapper.selectOneByExample(flowExample);
if(caseFlow != null){ if(caseFlow != null){
application.setCaseFlowId(caseFlow.getId()); application.setCaseFlowId(caseFlow.getId());
application.setCaseStatusName(caseFlow.getCaseStatusName()); application.setCaseStatusName(caseFlow.getCaseStatusName());
application.setMediaResult(mediaResult);
msCaseApplicationMapper.updateByPrimaryKey(application); msCaseApplicationMapper.updateByPrimaryKey(application);
// 新增日志 // 新增日志
CaseLogUtils.insertCaseLog(application.getId(), currentFlow.getNodeId(), currentFlow.getCaseStatusName(),""); CaseLogUtils.insertCaseLog(application.getId(), currentFlow.getNodeId(), currentFlow.getCaseStatusName(),"");
@@ -2927,7 +2957,7 @@ public class MsCaseApplicationServiceImpl implements MsCaseApplicationService {
} }
return AjaxResult.error(); return AjaxResult.success();
} }
/** /**
@@ -350,7 +350,7 @@ public class MsCasePaymentServiceImpl implements MsCasePaymentService {
} }
// 新增日志 // 新增日志
if (dto.getYesOrNo().equals(YesOrNoEnum.YES.getCode())) { if (dto.getYesOrNo().equals(YesOrNoEnum.YES.getCode())) {
CaseLogUtils.insertCaseLog(application.getId(), currentFlow.getNodeId(), currentFlow.getCaseStatusName(), "确认已缴费"); CaseLogUtils.insertCaseLog(application.getId(), currentFlow.getNodeId(), currentFlow.getCaseStatusName(), null);
}else { }else {
CaseLogUtils.insertCaseLog(application.getId(), currentFlow.getNodeId(), currentFlow.getCaseStatusName(), "拒绝确认缴费,拒绝原因为:"+dto.getReason()); CaseLogUtils.insertCaseLog(application.getId(), currentFlow.getNodeId(), currentFlow.getCaseStatusName(), "拒绝确认缴费,拒绝原因为:"+dto.getReason());
} }
@@ -509,7 +509,7 @@ public class MsCasePaymentServiceImpl implements MsCasePaymentService {
application.setCaseFlowId(nextFlow.getId()); application.setCaseFlowId(nextFlow.getId());
application.setCaseStatusName(nextFlow.getCaseStatusName()); application.setCaseStatusName(nextFlow.getCaseStatusName());
caseApplicationMapper.updateByPrimaryKeySelective(application); caseApplicationMapper.updateByPrimaryKeySelective(application);
CaseLogUtils.insertCaseLog(application.getId(), currentFlow.getNodeId(), currentFlow.getCaseStatusName(),"确认缴费"); CaseLogUtils.insertCaseLog(application.getId(), currentFlow.getNodeId(), currentFlow.getCaseStatusName(),null);
} }
@@ -411,7 +411,7 @@ public class MsSignSealServiceImpl implements MsSignSealService {
application.setCaseFlowId(nextFlow.getId()); application.setCaseFlowId(nextFlow.getId());
application.setCaseStatusName(nextFlow.getCaseStatusName()); application.setCaseStatusName(nextFlow.getCaseStatusName());
caseApplicationMapper.updateByPrimaryKeySelective(application); caseApplicationMapper.updateByPrimaryKeySelective(application);
CaseLogUtils.insertCaseLog(application.getId(), currentFlow.getNodeId(), currentFlow.getCaseStatusName(),"用印申请"); CaseLogUtils.insertCaseLog(application.getId(), currentFlow.getNodeId(), currentFlow.getCaseStatusName(),null);
} }
} else { } else {
// 单独 // 单独
@@ -421,7 +421,7 @@ public class MsSignSealServiceImpl implements MsSignSealService {
application.setCaseFlowId(nextFlow.getId()); application.setCaseFlowId(nextFlow.getId());
application.setCaseStatusName(nextFlow.getCaseStatusName()); application.setCaseStatusName(nextFlow.getCaseStatusName());
caseApplicationMapper.updateByPrimaryKeySelective(application); caseApplicationMapper.updateByPrimaryKeySelective(application);
CaseLogUtils.insertCaseLog(application.getId(), currentFlow.getNodeId(), currentFlow.getCaseStatusName(),"用印申请"); CaseLogUtils.insertCaseLog(application.getId(), currentFlow.getNodeId(), currentFlow.getCaseStatusName(),null);
} }
return AjaxResult.success("用印申请成功"); return AjaxResult.success("用印申请成功");
@@ -786,7 +786,7 @@ public class MsSignSealServiceImpl implements MsSignSealService {
caseApplicationselect.setCaseFlowId(nextFlow.getId()); caseApplicationselect.setCaseFlowId(nextFlow.getId());
caseApplicationselect.setCaseStatusName(nextFlow.getCaseStatusName()); caseApplicationselect.setCaseStatusName(nextFlow.getCaseStatusName());
caseApplicationMapper.updateByPrimaryKeySelective(caseApplicationselect); caseApplicationMapper.updateByPrimaryKeySelective(caseApplicationselect);
CaseLogUtils.insertCaseLog(caseApplicationselect.getId(), currentFlow.getNodeId(), currentFlow.getCaseStatusName(),"签收"); CaseLogUtils.insertCaseLog(caseApplicationselect.getId(), currentFlow.getNodeId(), currentFlow.getCaseStatusName(),null);
} }
// if (dto.getIsSignRespon() != null && dto.getIsSignRespon().intValue() == 1) { // if (dto.getIsSignRespon() != null && dto.getIsSignRespon().intValue() == 1) {
// caseAffiliate.setIsSignRespon(1); // caseAffiliate.setIsSignRespon(1);
@@ -810,7 +810,7 @@ public class MsSignSealServiceImpl implements MsSignSealService {
caseApplicationselect.setCaseFlowId(nextFlow.getId()); caseApplicationselect.setCaseFlowId(nextFlow.getId());
caseApplicationselect.setCaseStatusName(nextFlow.getCaseStatusName()); caseApplicationselect.setCaseStatusName(nextFlow.getCaseStatusName());
caseApplicationMapper.updateByPrimaryKeySelective(caseApplicationselect); caseApplicationMapper.updateByPrimaryKeySelective(caseApplicationselect);
CaseLogUtils.insertCaseLog(caseApplicationselect.getId(), currentFlow.getNodeId(), currentFlow.getCaseStatusName(),"签收"); CaseLogUtils.insertCaseLog(caseApplicationselect.getId(), currentFlow.getNodeId(), currentFlow.getCaseStatusName(),null);
} }
return AjaxResult.success("签收成功"); return AjaxResult.success("签收成功");
@@ -7,6 +7,6 @@ targetprojectpath=D:/ymPro/Mediation-Backend/ruoyi-system/src/main/resources/map
#模块名称 #模块名称
moduleName=mscase moduleName=mscase
#表名 #表名
tableName=ms_case_affiliate tableName=ms_case_audit
#主键 #主键
premaryId=id premaryId=id