bug修复
This commit is contained in:
+1
-1
@@ -165,7 +165,7 @@ public class MsCaseApplicationController extends BaseController {
|
||||
*/
|
||||
@PostMapping("/updateBooking")
|
||||
public AjaxResult updateBooking(@RequestBody BookingVO vo ) {
|
||||
if(vo.getId()==null || CollectionUtil.isEmpty(vo.getHerDates())|| CollectionUtil.isEmpty(vo.getUserList())){
|
||||
if(vo.getId()==null || CollectionUtil.isEmpty(vo.getUserList())){
|
||||
return error("参数校验失败");
|
||||
}
|
||||
return caseApplicationService.updateBooking(vo);
|
||||
|
||||
@@ -0,0 +1,63 @@
|
||||
package com.ruoyi.common.enums;
|
||||
|
||||
import com.ruoyi.common.interfaces.EnumsInterface;
|
||||
|
||||
/**
|
||||
* @author wangqiong
|
||||
* @description 选择调解员入口枚举
|
||||
* @date 2023-11-17 14:05
|
||||
*/
|
||||
public enum MediatorTypeEnum implements EnumsInterface
|
||||
{
|
||||
PC(0, "PC"),
|
||||
MI_NI_PROGRESS(1, "小程序"),
|
||||
|
||||
;
|
||||
|
||||
private final Integer code;
|
||||
private final String text;
|
||||
|
||||
MediatorTypeEnum(Integer code, String text)
|
||||
{
|
||||
this.code = code;
|
||||
this.text = text;
|
||||
}
|
||||
|
||||
public Integer getCode()
|
||||
{
|
||||
return code;
|
||||
}
|
||||
|
||||
public String getText()
|
||||
{
|
||||
return text;
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据code获取text
|
||||
* @param codeNo
|
||||
* @return
|
||||
*/
|
||||
public static String getTextByCode(Integer codeNo){
|
||||
for (MediatorTypeEnum value : MediatorTypeEnum.values()) {
|
||||
if (value.getCode().equals(codeNo)){
|
||||
return value.getText();
|
||||
}
|
||||
}
|
||||
return codeNo.toString();
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据text获取code
|
||||
* @param textStr
|
||||
* @return
|
||||
*/
|
||||
public static String getCodeByText(String textStr){
|
||||
for (MediatorTypeEnum value : MediatorTypeEnum.values()) {
|
||||
if (value.getText().equals(textStr)){
|
||||
return value.getText();
|
||||
}
|
||||
}
|
||||
return textStr;
|
||||
}
|
||||
}
|
||||
+1
-1
@@ -84,7 +84,7 @@ public class MsCaseApplication {
|
||||
* 调解员id
|
||||
*/
|
||||
@Column(name = "mediator_id")
|
||||
private String mediatorId;
|
||||
private Long mediatorId;
|
||||
|
||||
/**
|
||||
* 调解员名称
|
||||
|
||||
+1
-1
@@ -31,7 +31,7 @@ public class MsCaseMediator {
|
||||
* 调解员id
|
||||
*/
|
||||
@Column(name = "mediator_id")
|
||||
private String mediatorId;
|
||||
private Long mediatorId;
|
||||
|
||||
/**
|
||||
* 调解员名称
|
||||
|
||||
+16
-3
@@ -1,6 +1,7 @@
|
||||
package com.ruoyi.wisdomarbitrate.domain.vo.mscase;
|
||||
|
||||
import com.ruoyi.common.core.domain.entity.SysUser;
|
||||
import com.ruoyi.wisdomarbitrate.domain.entity.mscase.MsCaseMediator;
|
||||
import lombok.Data;
|
||||
|
||||
import java.util.List;
|
||||
@@ -15,13 +16,17 @@ import java.util.List;
|
||||
@Data
|
||||
public class BookingVO {
|
||||
/**
|
||||
* 调解员列表
|
||||
* 申请人调解员列表
|
||||
*/
|
||||
private List<SysUser> userList;
|
||||
/**
|
||||
* 调解员列表
|
||||
* 申请人调解员列表
|
||||
*/
|
||||
private List<MediatorVO> mediatorList;
|
||||
private List<MsCaseMediator> mediatorList;
|
||||
/**
|
||||
* 被申请人调解员列表
|
||||
*/
|
||||
private List<MsCaseMediator>resMediatorList;
|
||||
/**
|
||||
* 开庭日期集合
|
||||
*/
|
||||
@@ -38,6 +43,14 @@ public class BookingVO {
|
||||
* 批次
|
||||
*/
|
||||
private String batchNumber;
|
||||
/**
|
||||
* 调解员id
|
||||
*/
|
||||
private Long mediatorId;
|
||||
/**
|
||||
* 调解员
|
||||
*/
|
||||
private String mediatorName;
|
||||
/**
|
||||
* 是否被申请人,1-被申请人,空为申请人
|
||||
*/
|
||||
|
||||
+141
-94
@@ -13,6 +13,7 @@ import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.core.domain.entity.*;
|
||||
import com.ruoyi.common.core.domain.model.LoginUser;
|
||||
import com.ruoyi.common.enums.AnnexTypeEnum;
|
||||
import com.ruoyi.common.enums.MediatorTypeEnum;
|
||||
import com.ruoyi.common.enums.YesOrNoEnum;
|
||||
import com.ruoyi.common.exception.EsignDemoException;
|
||||
import com.ruoyi.common.exception.ServiceException;
|
||||
@@ -869,8 +870,8 @@ public class MsCaseApplicationServiceImpl implements MsCaseApplicationService {
|
||||
return AjaxResult.error("暂无调解员");
|
||||
}
|
||||
List<Long> userIds = users.stream().map(SysUser::getUserId).collect(Collectors.toList());
|
||||
// todo 状态为未结束的是待办数量,结束的是已办数量
|
||||
Map<String, List<MsCaseApplication>> caseMap=null;
|
||||
// 状态为未结束的是待办数量,结束的是已办数量
|
||||
Map<Long, List<MsCaseApplication>> caseMap=null;
|
||||
|
||||
List<MsCaseApplication> caseApplicationList = msCaseApplicationMapper.listMediator(userIds);
|
||||
if (CollectionUtil.isNotEmpty(caseApplicationList)) {
|
||||
@@ -885,8 +886,8 @@ public class MsCaseApplicationServiceImpl implements MsCaseApplicationService {
|
||||
if(caseMap==null){
|
||||
mediatorVO.setTodoAmount(0L);
|
||||
mediatorVO.setCompleteAmount(0L);
|
||||
} else if(caseMap.containsKey(String.valueOf(user.getUserId()))) {
|
||||
List<MsCaseApplication> applications = caseMap.get(String.valueOf(user.getUserId()));
|
||||
} else if(caseMap.containsKey(user.getUserId())) {
|
||||
List<MsCaseApplication> applications = caseMap.get(user.getUserId());
|
||||
// 已办案件
|
||||
long count = applications.stream().filter(caseApplication -> !caseApplication.getCaseStatusName().equals("结束")).count();
|
||||
mediatorVO.setTodoAmount(applications.size()-count);
|
||||
@@ -914,14 +915,18 @@ public class MsCaseApplicationServiceImpl implements MsCaseApplicationService {
|
||||
if (currentFlow == null) {
|
||||
return AjaxResult.error("当前流程不存在");
|
||||
}
|
||||
// 获取选择的调解员id
|
||||
List<Long> userIds = vo.getUserList().stream().map(SysUser::getUserId).collect(Collectors.toList());
|
||||
// 新增案件预约表
|
||||
MsCaseMediator mediator = new MsCaseMediator();
|
||||
mediator.setCaseAppliId(vo.getId());
|
||||
mediator.setMediatorId(String.valueOf(vo.getUserList().get(0).getUserId()));
|
||||
mediator.setMediatorName(String.valueOf(vo.getUserList().get(0).getUserName()));
|
||||
mediator.setHearDate(String.valueOf(vo.getHerDates().get(0)));
|
||||
mediator.setType(vo.getMiniProgressFlag());
|
||||
msCaseMediatorMapper.insert(mediator);
|
||||
for (SysUser sysUser : vo.getUserList()) {
|
||||
MsCaseMediator mediator = new MsCaseMediator();
|
||||
mediator.setCaseAppliId(vo.getId());
|
||||
mediator.setMediatorId(sysUser.getUserId());
|
||||
mediator.setMediatorName(sysUser.getNickName());
|
||||
mediator.setType(vo.getMiniProgressFlag()==null?MediatorTypeEnum.PC.getCode() : vo.getMiniProgressFlag());
|
||||
msCaseMediatorMapper.insert(mediator);
|
||||
}
|
||||
|
||||
// 申请人预约
|
||||
if (vo.getMiniProgressFlag() == null) {
|
||||
// 新增日志
|
||||
@@ -931,12 +936,12 @@ public class MsCaseApplicationServiceImpl implements MsCaseApplicationService {
|
||||
return AjaxResult.error("被申请人身份证为空");
|
||||
}
|
||||
|
||||
SysUser user = userMapper.selectUserByIdCard(msCaseAffiliate.getRespondentIdentityNum());
|
||||
// SysUser user = userMapper.selectUserByIdCard(msCaseAffiliate.getRespondentIdentityNum());
|
||||
// 被申请人存在
|
||||
if (user != null) {
|
||||
// if (user != null) {
|
||||
// 判断被申请人信息查询案件预约表
|
||||
isReservation( vo,user);
|
||||
}
|
||||
isReservation( vo,userIds);
|
||||
// }
|
||||
|
||||
} else {
|
||||
// 被申请人预约
|
||||
@@ -946,11 +951,11 @@ public class MsCaseApplicationServiceImpl implements MsCaseApplicationService {
|
||||
return AjaxResult.error("申请代理人手机号为空");
|
||||
}
|
||||
|
||||
SysUser user = userMapper.selectUserByPhone(msCaseAffiliate.getContactTelphoneAgent());
|
||||
if(user!=null){
|
||||
// SysUser user = userMapper.selectUserByPhone(msCaseAffiliate.getContactTelphoneAgent());
|
||||
// if(user!=null){
|
||||
// 判断申请人是否预约
|
||||
isReservation( vo,user);
|
||||
}
|
||||
isReservation( vo,userIds);
|
||||
// }
|
||||
|
||||
}
|
||||
return AjaxResult.success();
|
||||
@@ -959,9 +964,15 @@ public class MsCaseApplicationServiceImpl implements MsCaseApplicationService {
|
||||
/**
|
||||
* 判断申请人/被申请人是否预约
|
||||
* @param vo
|
||||
* @param user
|
||||
* @param userIds 选择的调解员ids
|
||||
*/
|
||||
private void isReservation( BookingVO vo, SysUser user) {
|
||||
private void isReservation( BookingVO vo, List<Long> userIds ) {
|
||||
// 查询所有调解员
|
||||
List<SysUser> mediatorUsers = sysUserMapper.selectUserByRole("调解员");
|
||||
if (CollectionUtil.isEmpty(mediatorUsers)) {
|
||||
throw new ServiceException("暂无调解员");
|
||||
}
|
||||
Map<Long, SysUser> userMap = mediatorUsers.stream().collect(Collectors.toMap(SysUser::getUserId, Function.identity()));
|
||||
Example example = new Example(MsCaseMediator.class);
|
||||
Example.Criteria criteria = example.createCriteria();
|
||||
if(vo.getMiniProgressFlag() == null) {
|
||||
@@ -973,14 +984,50 @@ public class MsCaseApplicationServiceImpl implements MsCaseApplicationService {
|
||||
}
|
||||
criteria.andEqualTo("caseAppliId", vo.getId());
|
||||
// criteria.andEqualTo("mediatorId", user.getUserId());
|
||||
int count = msCaseMediatorMapper.selectCountByExample(example);
|
||||
if (count > 0) {
|
||||
// 申请人已预约,更新主表流程节点
|
||||
List<MsCaseMediator> msCaseMediators = msCaseMediatorMapper.selectByExample(example);
|
||||
if (CollectionUtil.isNotEmpty(msCaseMediators)) {
|
||||
MsCaseApplication application = new MsCaseApplication();
|
||||
// 申请人或者被申请人已预约,更新主表流程节点
|
||||
MsCaseFlow nextFlow = caseFlowMapper.nextFlow(vo.getCaseFlowId());
|
||||
if (nextFlow == null) {
|
||||
throw new ServiceException("未找到下一个流程");
|
||||
}
|
||||
MsCaseApplication application = new MsCaseApplication();
|
||||
// 取出另一方的调解员id
|
||||
List<Long> mediatorIds = msCaseMediators.stream().map(MsCaseMediator::getMediatorId).collect(Collectors.toList());
|
||||
// 取出申请人和被申请人选择调解员交集,交集>1,根据优先级确定调解员(优先级查调解员已结束的案件)
|
||||
List<Long> intersectionWithoutModifyOriginal = new ArrayList<>(userIds);
|
||||
// 交集
|
||||
List<Long> intersection = new ArrayList<>(intersectionWithoutModifyOriginal);
|
||||
intersection.retainAll(mediatorIds);
|
||||
// 有一个交集,则直接更新主表调解员
|
||||
if(intersection.size()==1){
|
||||
application.setMediatorId(intersection.get(0));
|
||||
application.setMediatorName(userMap.get(intersection.get(0)).getNickName());
|
||||
}else if(intersection.size()>1){
|
||||
// 查询调解员的案件,有多个交集,根据优先级获取
|
||||
List<MsCaseApplication> caseApplicationList = msCaseApplicationMapper.listMediator(userIds);
|
||||
if (CollectionUtil.isNotEmpty(caseApplicationList)) {
|
||||
Map<Long, List<MsCaseApplication>> caseMap = caseApplicationList.stream().collect(Collectors.groupingBy(MsCaseApplication::getMediatorId, Collectors.toList()));
|
||||
long maxCount=0;
|
||||
for (Long userId : intersection) {
|
||||
if (caseMap.containsKey(userId)) {
|
||||
List<MsCaseApplication> applications = caseMap.get(userId);
|
||||
// 已办案件
|
||||
long count = applications.stream().filter(caseApplication -> !caseApplication.getCaseStatusName().equals("结束")).count();
|
||||
if(count>=maxCount){
|
||||
maxCount=count;
|
||||
application.setMediatorId(userId);
|
||||
application.setMediatorName(userMap.get(userId).getNickName());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}else {
|
||||
// 没有案件,则随机取一个调解员
|
||||
application.setMediatorId(intersection.get(0));
|
||||
application.setMediatorName(userMap.get(intersection.get(0)).getNickName());
|
||||
}
|
||||
}
|
||||
application.setId(vo.getId());
|
||||
application.setCaseFlowId(nextFlow.getId());
|
||||
application.setCaseStatusName(nextFlow.getCaseStatusName());
|
||||
@@ -1002,21 +1049,21 @@ public class MsCaseApplicationServiceImpl implements MsCaseApplicationService {
|
||||
* @param application
|
||||
* @param vo
|
||||
*/
|
||||
private void setMediatorAndDate(MsCaseApplication application, BookingVO vo) {
|
||||
if(CollectionUtil.isNotEmpty(vo.getUserList())) {
|
||||
List<SysUser> userList = vo.getUserList();
|
||||
List<Long> userIds = userList.stream().map(SysUser::getUserId).collect(Collectors.toList());
|
||||
List<String> userNames = userList.stream().map(SysUser::getUserName).collect(Collectors.toList());
|
||||
String mediatorIds = StrUtil.join(",", userIds);
|
||||
String mediatorNames = StrUtil.join(",", userNames);
|
||||
application.setMediatorId(mediatorIds);
|
||||
application.setMediatorName(mediatorNames);
|
||||
}
|
||||
if(CollectionUtil.isNotEmpty( vo.getHerDates())) {
|
||||
String herDates = StrUtil.join(",", vo.getHerDates());
|
||||
application.setHearDate(herDates);
|
||||
}
|
||||
}
|
||||
// private void setMediatorAndDate(MsCaseApplication application, BookingVO vo) {
|
||||
// if(CollectionUtil.isNotEmpty(vo.getUserList())) {
|
||||
// List<SysUser> userList = vo.getUserList();
|
||||
// List<Long> userIds = userList.stream().map(SysUser::getUserId).collect(Collectors.toList());
|
||||
// List<String> userNames = userList.stream().map(SysUser::getUserName).collect(Collectors.toList());
|
||||
// String mediatorIds = StrUtil.join(",", userIds);
|
||||
// String mediatorNames = StrUtil.join(",", userNames);
|
||||
// application.setMediatorId(mediatorIds);
|
||||
// application.setMediatorName(mediatorNames);
|
||||
// }
|
||||
// if(CollectionUtil.isNotEmpty( vo.getHerDates())) {
|
||||
// String herDates = StrUtil.join(",", vo.getHerDates());
|
||||
// application.setHearDate(herDates);
|
||||
// }
|
||||
// }
|
||||
|
||||
/**
|
||||
* 核实调解员
|
||||
@@ -1049,60 +1096,58 @@ public class MsCaseApplicationServiceImpl implements MsCaseApplicationService {
|
||||
*/
|
||||
@Override
|
||||
public AjaxResult selectReservation(Long id) {
|
||||
// 查询案件主表
|
||||
MsCaseApplication application = msCaseApplicationMapper.selectByPrimaryKey(id);
|
||||
if (application == null) {
|
||||
return AjaxResult.error("该案件不存在");
|
||||
}
|
||||
BookingVO result = new BookingVO();
|
||||
|
||||
// MsCaseApplication caseApplication = msCaseApplicationMapper.selectByPrimaryKey(id);
|
||||
// todo 返回申请人预约信息,预约信息查预约表
|
||||
// criteria.andEqualTo("mediatorId", SecurityUtils.getUserId());
|
||||
MsCaseMediator msCaseMediator = msCaseMediatorMapper.selectLastApplicant(id);
|
||||
if(msCaseMediator==null){
|
||||
result.setMediatorId(application.getMediatorId());
|
||||
result.setMediatorName(application.getMediatorName());
|
||||
Example example = new Example(MsCaseAffiliate.class);
|
||||
example.createCriteria().andEqualTo("caseAppliId", id);
|
||||
List<MsCaseMediator> msCaseMediators = msCaseMediatorMapper.selectByExample(example);
|
||||
if(CollectionUtil.isEmpty(msCaseMediators)){
|
||||
return AjaxResult.success(result);
|
||||
}
|
||||
// if(caseApplication == null){
|
||||
// return AjaxResult.error("该案件不存在");
|
||||
// }
|
||||
Map<Integer, List<MsCaseMediator>> mediatorMap = msCaseMediators.stream().collect(Collectors.groupingBy(MsCaseMediator::getType));
|
||||
// 申请人
|
||||
result.setMediatorList(mediatorMap.get(MediatorTypeEnum.PC.getCode()));
|
||||
result.setResMediatorList(mediatorMap.get(MediatorTypeEnum.MI_NI_PROGRESS.getCode()));
|
||||
|
||||
// 调解员是一个的处理
|
||||
if( StrUtil.isNotEmpty(msCaseMediator.getMediatorId()) && StrUtil.isNotEmpty(msCaseMediator.getMediatorName())){
|
||||
// 查询用户
|
||||
SysUser user = userMapper.selectUserById(Long.valueOf(msCaseMediator.getMediatorId()));
|
||||
if(user==null){
|
||||
return AjaxResult.error("调解员已被删除");
|
||||
}
|
||||
// 查询待办数量
|
||||
List<Long> mediatorIds = new ArrayList<>();
|
||||
mediatorIds.add(user.getUserId());
|
||||
Map<String, List<MsCaseApplication>> caseMap=null;
|
||||
List<MsCaseApplication> caseApplicationList = msCaseApplicationMapper.listMediator(mediatorIds);
|
||||
if (CollectionUtil.isNotEmpty(caseApplicationList)) {
|
||||
caseMap = caseApplicationList.stream().collect(Collectors.groupingBy(MsCaseApplication::getMediatorId, Collectors.toList()));
|
||||
// SysUser user = userMapper.selectUserById(Long.valueOf(msCaseMediator.getMediatorId()));
|
||||
// if(user==null){
|
||||
// return AjaxResult.error("调解员已被删除");
|
||||
// }
|
||||
// // 查询待办数量
|
||||
// List<Long> mediatorIds = new ArrayList<>();
|
||||
// mediatorIds.add(user.getUserId());
|
||||
// Map<Long, List<MsCaseApplication>> caseMap=null;
|
||||
// List<MsCaseApplication> caseApplicationList = msCaseApplicationMapper.listMediator(mediatorIds);
|
||||
// if (CollectionUtil.isNotEmpty(caseApplicationList)) {
|
||||
// caseMap = caseApplicationList.stream().collect(Collectors.groupingBy(MsCaseApplication::getMediatorId, Collectors.toList()));
|
||||
//
|
||||
// }
|
||||
// MediatorVO mediatorVO = new MediatorVO();
|
||||
// mediatorVO.setMediatorId(user.getUserId());
|
||||
// mediatorVO.setMediatorName(user.getNickName());
|
||||
// mediatorVO.setSpecialty(user.getSpecialty());
|
||||
// if(caseMap==null){
|
||||
// mediatorVO.setTodoAmount(0L);
|
||||
// mediatorVO.setCompleteAmount(0L);
|
||||
// }
|
||||
//
|
||||
// else if(caseMap.containsKey(String.valueOf(user.getUserId()))) {
|
||||
// List<MsCaseApplication> applications = caseMap.get(String.valueOf(user.getUserId()));
|
||||
// // 已办案件
|
||||
// long count = applications.stream().filter(caseApplication -> !caseApplication.getCaseStatusName().equals("结束")).count();
|
||||
// mediatorVO.setTodoAmount(applications.size()-count);
|
||||
// mediatorVO.setCompleteAmount(count);
|
||||
// }
|
||||
|
||||
|
||||
}
|
||||
MediatorVO mediatorVO = new MediatorVO();
|
||||
mediatorVO.setMediatorId(user.getUserId());
|
||||
mediatorVO.setMediatorName(user.getNickName());
|
||||
mediatorVO.setSpecialty(user.getSpecialty());
|
||||
if(caseMap==null){
|
||||
mediatorVO.setTodoAmount(0L);
|
||||
mediatorVO.setCompleteAmount(0L);
|
||||
}
|
||||
|
||||
else if(caseMap.containsKey(String.valueOf(user.getUserId()))) {
|
||||
List<MsCaseApplication> applications = caseMap.get(String.valueOf(user.getUserId()));
|
||||
// 已办案件
|
||||
long count = applications.stream().filter(caseApplication -> !caseApplication.getCaseStatusName().equals("结束")).count();
|
||||
mediatorVO.setTodoAmount(applications.size()-count);
|
||||
mediatorVO.setCompleteAmount(count);
|
||||
}
|
||||
List<MediatorVO> mediatorVOS = new ArrayList<>();
|
||||
mediatorVOS.add(mediatorVO);
|
||||
result.setMediatorList(mediatorVOS);
|
||||
}
|
||||
if(StrUtil.isNotEmpty(msCaseMediator.getHearDate())){
|
||||
List<String> herdates = new ArrayList<>();
|
||||
herdates.add(msCaseMediator.getHearDate());
|
||||
result.setHerDates(herdates);
|
||||
}
|
||||
return AjaxResult.success(result);
|
||||
}
|
||||
|
||||
@@ -1220,9 +1265,9 @@ public class MsCaseApplicationServiceImpl implements MsCaseApplicationService {
|
||||
//发起签署
|
||||
sealSignRecord.setFilename(fileName);
|
||||
|
||||
String arbitratorId = caseApplication.getMediatorId();
|
||||
if (StringUtils.isNotEmpty(arbitratorId)) {
|
||||
SysUser sysUser = sysUserMapper.selectUserById(Long.valueOf(arbitratorId));
|
||||
Long arbitratorId = caseApplication.getMediatorId();
|
||||
if (null!=arbitratorId) {
|
||||
SysUser sysUser = sysUserMapper.selectUserById(arbitratorId);
|
||||
if (sysUser == null) {
|
||||
return AjaxResult.error();
|
||||
}
|
||||
@@ -1483,9 +1528,9 @@ public class MsCaseApplicationServiceImpl implements MsCaseApplicationService {
|
||||
//发起签署
|
||||
sealSignRecord.setFilename(fileName);
|
||||
|
||||
String arbitratorId = caseApplication.getMediatorId();
|
||||
if (StringUtils.isNotEmpty(arbitratorId)) {
|
||||
SysUser sysUser = sysUserMapper.selectUserById(Long.valueOf(arbitratorId));
|
||||
Long arbitratorId = caseApplication.getMediatorId();
|
||||
if (arbitratorId!=null) {
|
||||
SysUser sysUser = sysUserMapper.selectUserById(arbitratorId);
|
||||
if (sysUser == null) {
|
||||
return AjaxResult.error();
|
||||
}
|
||||
@@ -1727,7 +1772,9 @@ public class MsCaseApplicationServiceImpl implements MsCaseApplicationService {
|
||||
if (nextFlow == null) {
|
||||
throw new ServiceException("未找到下一个流程节点");
|
||||
}
|
||||
setMediatorAndDate(application,vo);
|
||||
// setMediatorAndDate(application,vo);
|
||||
application.setMediatorId(vo.getUserList().get(0).getUserId());
|
||||
application.setMediatorName(vo.getUserList().get(0).getNickName());
|
||||
application.setCaseFlowId(nextFlow.getNodeId());
|
||||
application.setCaseStatusName(nextFlow.getCaseStatusName());
|
||||
msCaseApplicationMapper.updateByPrimaryKeySelective(application);
|
||||
|
||||
+7
-10
@@ -10,7 +10,6 @@ import com.alibaba.fastjson.JSONObject;
|
||||
import com.google.gson.Gson;
|
||||
import com.google.gson.JsonArray;
|
||||
import com.google.gson.JsonObject;
|
||||
import com.ruoyi.common.constant.CaseApplicationConstants;
|
||||
import com.ruoyi.common.constant.FileTransformation;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.core.domain.entity.EsignHttpResponse;
|
||||
@@ -21,7 +20,6 @@ import com.ruoyi.common.exception.EsignDemoException;
|
||||
import com.ruoyi.common.exception.ServiceException;
|
||||
import com.ruoyi.common.utils.EmailOutUtil;
|
||||
import com.ruoyi.common.utils.SmsUtils;
|
||||
import com.ruoyi.common.utils.StringUtils;
|
||||
import com.ruoyi.common.utils.file.SaaSAPIFileUtils;
|
||||
import com.ruoyi.system.domain.entity.flow.MsCaseFlow;
|
||||
import com.ruoyi.system.mapper.SysUserMapper;
|
||||
@@ -31,9 +29,11 @@ import com.ruoyi.wisdomarbitrate.domain.dto.dept.SealManage;
|
||||
import com.ruoyi.wisdomarbitrate.domain.dto.mscase.CaseLogRecord;
|
||||
import com.ruoyi.wisdomarbitrate.domain.dto.mscase.MsSignSealDTO;
|
||||
import com.ruoyi.wisdomarbitrate.domain.dto.mscase.SealSignRecord;
|
||||
import com.ruoyi.wisdomarbitrate.domain.dto.sendrecord.SendMailRecord;
|
||||
import com.ruoyi.wisdomarbitrate.domain.entity.dept.MsSealSignRecord;
|
||||
import com.ruoyi.wisdomarbitrate.domain.entity.mscase.*;
|
||||
import com.ruoyi.wisdomarbitrate.domain.entity.mscase.MsCaseAffiliate;
|
||||
import com.ruoyi.wisdomarbitrate.domain.entity.mscase.MsCaseApplication;
|
||||
import com.ruoyi.wisdomarbitrate.domain.entity.mscase.MsCaseAttach;
|
||||
import com.ruoyi.wisdomarbitrate.domain.entity.mscase.MsCaseLogRecord;
|
||||
import com.ruoyi.wisdomarbitrate.domain.vo.mscase.MsCaseApplicationVO;
|
||||
import com.ruoyi.wisdomarbitrate.domain.vo.mscase.MsCaseLogRecordVO;
|
||||
import com.ruoyi.wisdomarbitrate.mapper.dept.DeptIdentifyMapper;
|
||||
@@ -53,13 +53,10 @@ import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
import tk.mybatis.mapper.entity.Example;
|
||||
|
||||
import static com.ruoyi.common.utils.SecurityUtils.getUsername;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.io.File;
|
||||
import java.time.LocalDate;
|
||||
import java.util.*;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
import static com.ruoyi.common.core.domain.AjaxResult.success;
|
||||
|
||||
@@ -151,9 +148,9 @@ public class MsSignSealServiceImpl implements MsSignSealService {
|
||||
//发起签署
|
||||
sealSignRecord.setFilename(fileName);
|
||||
|
||||
String arbitratorId = caseApplication.getMediatorId();
|
||||
if (StringUtils.isNotEmpty(arbitratorId)) {
|
||||
SysUser sysUser = sysUserMapper.selectUserById(Long.valueOf(arbitratorId));
|
||||
Long arbitratorId = caseApplication.getMediatorId();
|
||||
if (arbitratorId!=null) {
|
||||
SysUser sysUser = sysUserMapper.selectUserById(arbitratorId);
|
||||
if (sysUser == null) {
|
||||
return AjaxResult.error();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user