Commit a44c3271 authored by tianbo's avatar tianbo

隐患流程修改

parent 25977a48
...@@ -13,7 +13,8 @@ import com.alibaba.fastjson.JSONObject; ...@@ -13,7 +13,8 @@ import com.alibaba.fastjson.JSONObject;
import feign.Response; import feign.Response;
@FeignClient(name = "AMOS-API-WORKFLOW", path = "workflow", configuration = { CommonMultipartSupportConfig.class }) @FeignClient(name = "AMOS-API-WORKFLOW-chenhao", path = "workflow", configuration =
{ CommonMultipartSupportConfig.class })
public interface WorkflowFeignService { public interface WorkflowFeignService {
/** /**
* 发起流程 * 发起流程
......
...@@ -50,6 +50,9 @@ public class LatentDangerFlowRecord extends BasicEntity { ...@@ -50,6 +50,9 @@ public class LatentDangerFlowRecord extends BasicEntity {
@Column(name = "execute_user_id") @Column(name = "execute_user_id")
private String executeUserId; private String executeUserId;
@Column(name = "execute_user_name")
private String executeUserName;
@Column(name = "execute_result") @Column(name = "execute_result")
private String executeResult; private String executeResult;
...@@ -74,4 +77,7 @@ public class LatentDangerFlowRecord extends BasicEntity { ...@@ -74,4 +77,7 @@ public class LatentDangerFlowRecord extends BasicEntity {
@Column(name = "execute_department_id") @Column(name = "execute_department_id")
private String executeDepartmentId; private String executeDepartmentId;
@Column(name = "execute_department_name")
private String executeDepartmentName;
} }
...@@ -146,9 +146,8 @@ public class LatentDangerController extends BaseController { ...@@ -146,9 +146,8 @@ public class LatentDangerController extends BaseController {
String departmentName = getDepartmentName(reginParams); String departmentName = getDepartmentName(reginParams);
String userRealName = user.getRealName(); String userRealName = user.getRealName();
String userId = user.getUserId(); String userId = user.getUserId();
RoleBo role = reginParams.getRole();
DangerExecuteSubmitDto executeSubmitDto = iLatentDangerService.execute(latentDangerExecuteParam, userId, DangerExecuteSubmitDto executeSubmitDto = iLatentDangerService.execute(latentDangerExecuteParam, userId,
userRealName, deptId, departmentName, role); userRealName, deptId, departmentName, reginParams);
// iLatentDangerService.freshRiskJudgmentLangerCount(latentDangerExecuteParam);//更新统计 // iLatentDangerService.freshRiskJudgmentLangerCount(latentDangerExecuteParam);//更新统计
// 执行通过,发送执行结果消息 // 执行通过,发送执行结果消息
// if (executeSubmitDto.getIsOk()) { // if (executeSubmitDto.getIsOk()) {
......
...@@ -4,7 +4,6 @@ import com.alibaba.fastjson.JSON; ...@@ -4,7 +4,6 @@ import com.alibaba.fastjson.JSON;
import com.alibaba.fastjson.JSONArray; import com.alibaba.fastjson.JSONArray;
import com.alibaba.fastjson.JSONObject; import com.alibaba.fastjson.JSONObject;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage; import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page; import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.google.common.base.Joiner; import com.google.common.base.Joiner;
...@@ -12,6 +11,7 @@ import com.google.common.collect.Lists; ...@@ -12,6 +11,7 @@ import com.google.common.collect.Lists;
import com.google.common.collect.Maps; import com.google.common.collect.Maps;
import com.google.common.collect.Sets; import com.google.common.collect.Sets;
import com.yeejoin.amos.boot.biz.common.bo.DepartmentBo; import com.yeejoin.amos.boot.biz.common.bo.DepartmentBo;
import com.yeejoin.amos.boot.biz.common.bo.ReginParams;
import com.yeejoin.amos.boot.biz.common.bo.RoleBo; import com.yeejoin.amos.boot.biz.common.bo.RoleBo;
import com.yeejoin.amos.boot.biz.common.service.impl.WorkflowExcuteServiceImpl; import com.yeejoin.amos.boot.biz.common.service.impl.WorkflowExcuteServiceImpl;
import com.yeejoin.amos.boot.biz.common.utils.RedisUtils; import com.yeejoin.amos.boot.biz.common.utils.RedisUtils;
...@@ -209,7 +209,9 @@ public class LatentDangerServiceImpl extends BaseService<LatentDangerBo, LatentD ...@@ -209,7 +209,9 @@ public class LatentDangerServiceImpl extends BaseService<LatentDangerBo, LatentD
latentDanger.setInstanceId(instance.getString("id")); latentDanger.setInstanceId(instance.getString("id"));
JSONObject flowJson = new JSONObject(); JSONObject flowJson = new JSONObject();
flowJson.put("photoUrls", latentDangerDto.getPhotoUrl()); flowJson.put("photoUrls", latentDangerDto.getPhotoUrl());
LatentDangerFlowRecord record = saveFlowRecord(instance.getString("id"), "提交隐患", userId, departmentId, flowJson, dangerId, role, LatentDangerExecuteTypeEnum.填写隐患完成.getName(), latentDangerDto.getRemark()); LatentDangerFlowRecord record = saveFlowRecord(instance.getString("id"), "提交隐患", userId, departmentId,
flowJson, dangerId, role, LatentDangerExecuteTypeEnum.填写隐患完成.getName(), latentDangerDto.getRemark(),
userRealName, departmentName, latentDanger.getDangerState());
latentDanger.setCurrentFlowRecordId(record.getId()); latentDanger.setCurrentFlowRecordId(record.getId());
latentDangerMapper.updateById(latentDanger); latentDangerMapper.updateById(latentDanger);
sendMessage(latentDanger, LatentDangerExecuteTypeEnum.填写隐患完成, null, sendMessage(latentDanger, LatentDangerExecuteTypeEnum.填写隐患完成, null,
...@@ -286,7 +288,7 @@ public class LatentDangerServiceImpl extends BaseService<LatentDangerBo, LatentD ...@@ -286,7 +288,7 @@ public class LatentDangerServiceImpl extends BaseService<LatentDangerBo, LatentD
// 第一次保存隐患提交记录 // 第一次保存隐患提交记录
LatentDangerFlowRecord inputRecord = saveFlowRecord(instance.getString("id"), "提交隐患", userId, departmentId, LatentDangerFlowRecord inputRecord = saveFlowRecord(instance.getString("id"), "提交隐患", userId, departmentId,
flowJson, latentDanger.getId(), role, LatentDangerExecuteTypeEnum.填写隐患完成.getName(), flowJson, latentDanger.getId(), role, LatentDangerExecuteTypeEnum.填写隐患完成.getName(),
latentDanger.getRemark()); latentDanger.getRemark(), userRealName, departmentName, latentDanger.getDangerState());
latentDanger.setCurrentFlowRecordId(inputRecord.getId()); latentDanger.setCurrentFlowRecordId(inputRecord.getId());
latentDanger.setInstanceId(instance.getString("id")); latentDanger.setInstanceId(instance.getString("id"));
latentDangerMapper.updateById(latentDanger); latentDangerMapper.updateById(latentDanger);
...@@ -383,17 +385,22 @@ public class LatentDangerServiceImpl extends BaseService<LatentDangerBo, LatentD ...@@ -383,17 +385,22 @@ public class LatentDangerServiceImpl extends BaseService<LatentDangerBo, LatentD
} }
public LatentDangerFlowRecord saveFlowRecord(String taskId, String taskName, String userId, String departmentId, public LatentDangerFlowRecord saveFlowRecord(String taskId, String taskName, String userId, String departmentId,
JSONObject flowJson, Long dangerId, RoleBo role, String executeResult, String remark) { JSONObject flowJson, Long dangerId, RoleBo role,
String executeResult, String remark, String userName,
String departmentName, String dangerState) {
LatentDangerFlowRecord record = new LatentDangerFlowRecord(); LatentDangerFlowRecord record = new LatentDangerFlowRecord();
record.setFlowTaskId(taskId); record.setFlowTaskId(taskId);
record.setExecuteUserId(userId); record.setExecuteUserId(userId);
record.setExecuteUserName(userName);
record.setExecuteDepartmentId(departmentId); record.setExecuteDepartmentId(departmentId);
record.setExecuteDepartmentName(departmentName);
record.setFlowJson(flowJson != null ? flowJson.toJSONString() : null); record.setFlowJson(flowJson != null ? flowJson.toJSONString() : null);
record.setFlowTaskName(taskName); record.setFlowTaskName(taskName);
record.setDangerId(dangerId); record.setDangerId(dangerId);
record.setExecuteResult(executeResult); record.setExecuteResult(executeResult);
record.setActionFlag(taskName); record.setActionFlag(dangerState);
record.setRemark(remark); record.setRemark(remark);
record.setUpdateDate(new Date());
latentDangerFlowRecordService.saveOrUpdate(record); latentDangerFlowRecordService.saveOrUpdate(record);
return record; return record;
} }
...@@ -406,6 +413,7 @@ public class LatentDangerServiceImpl extends BaseService<LatentDangerBo, LatentD ...@@ -406,6 +413,7 @@ public class LatentDangerServiceImpl extends BaseService<LatentDangerBo, LatentD
record.setFlowTaskName(taskName); record.setFlowTaskName(taskName);
record.setActionFlag(taskDefinitionKey); record.setActionFlag(taskDefinitionKey);
record.setDangerId(dangerId); record.setDangerId(dangerId);
record.setUpdateDate(new Date());
latentDangerFlowRecordMapper.save(record); latentDangerFlowRecordMapper.save(record);
return record; return record;
} }
...@@ -618,7 +626,8 @@ public class LatentDangerServiceImpl extends BaseService<LatentDangerBo, LatentD ...@@ -618,7 +626,8 @@ public class LatentDangerServiceImpl extends BaseService<LatentDangerBo, LatentD
@Transactional(rollbackFor = Exception.class) @Transactional(rollbackFor = Exception.class)
@Override @Override
public DangerExecuteSubmitDto execute(LatentDangerExecuteParam latentDangerExecuteParam, String userId, String userRealName, String departmentId, String departmentName, RoleBo role) throws Exception { public DangerExecuteSubmitDto execute(LatentDangerExecuteParam latentDangerExecuteParam, String userId, String userRealName, String departmentId, String departmentName, ReginParams reginParams) throws Exception {
DangerExecuteSubmitDto executeSubmitDto = new DangerExecuteSubmitDto(); DangerExecuteSubmitDto executeSubmitDto = new DangerExecuteSubmitDto();
LatentDanger latentDanger = latentDangerMapper.selectById(latentDangerExecuteParam.getDangerId()); LatentDanger latentDanger = latentDangerMapper.selectById(latentDangerExecuteParam.getDangerId());
if (ValidationUtil.isEmpty(latentDanger)) { if (ValidationUtil.isEmpty(latentDanger)) {
...@@ -627,7 +636,8 @@ public class LatentDangerServiceImpl extends BaseService<LatentDangerBo, LatentD ...@@ -627,7 +636,8 @@ public class LatentDangerServiceImpl extends BaseService<LatentDangerBo, LatentD
return executeSubmitDto; return executeSubmitDto;
} }
DangerExecuteSubmitDto dangerExecuteSubmitDto = executeSubmit(latentDangerExecuteParam, latentDanger, userId, userRealName, departmentId, departmentName, executeSubmitDto, role); DangerExecuteSubmitDto dangerExecuteSubmitDto = executeSubmit(latentDangerExecuteParam, latentDanger, userId,
userRealName, departmentId, departmentName, executeSubmitDto, reginParams);
try { try {
if (dangerExecuteSubmitDto.getIsOk()) { if (dangerExecuteSubmitDto.getIsOk()) {
webMqttComponent.publish(dangerTopic, ""); webMqttComponent.publish(dangerTopic, "");
...@@ -691,6 +701,17 @@ public class LatentDangerServiceImpl extends BaseService<LatentDangerBo, LatentD ...@@ -691,6 +701,17 @@ public class LatentDangerServiceImpl extends BaseService<LatentDangerBo, LatentD
List<String> photoUrls = Lists.newArrayList(latentDanger.getPhotoUrls().split(",")); List<String> photoUrls = Lists.newArrayList(latentDanger.getPhotoUrls().split(","));
detailVo.setPhotoUrl(photoUrls); detailVo.setPhotoUrl(photoUrls);
} }
if (!ValidationUtil.isEmpty(detailVo.getReformLimitDate())) {
detailVo.setReformLimitDateStr(DateUtil.date2Str(detailVo.getReformLimitDate(), DateUtil.DATETIME_DEFAULT_FORMAT));
}
List<LatentDangerFlowRecordBo> records = latentDangerFlowRecordMapper.listByDangerId(latentDanger.getId());
if (!CollectionUtils.isEmpty(records)) {
for (LatentDangerFlowRecordBo recordBo : records) {
recordBo.setExecuteTime(DateUtil.date2Str(recordBo.getCreateDate(), DateUtil.DATETIME_DEFAULT_FORMAT));
}
detailVo.setRecords(records);
}
if (dangerBizType.equals(LatentDangerBizTypeEnum.巡检.getCode())) { if (dangerBizType.equals(LatentDangerBizTypeEnum.巡检.getCode())) {
// buildOfDifferentDangerType(latentDangerBo, detailVo); // buildOfDifferentDangerType(latentDangerBo, detailVo);
...@@ -1085,22 +1106,26 @@ public class LatentDangerServiceImpl extends BaseService<LatentDangerBo, LatentD ...@@ -1085,22 +1106,26 @@ public class LatentDangerServiceImpl extends BaseService<LatentDangerBo, LatentD
String departmentId, String departmentId,
String departmentName, String departmentName,
DangerExecuteSubmitDto executeSubmitDto, DangerExecuteSubmitDto executeSubmitDto,
RoleBo role) throws Exception { ReginParams reginParams) throws Exception {
// 根据业务类型不同执行不同逻辑 // 根据业务类型不同执行不同逻辑
if (LatentDangerBizTypeEnum.防火监督.getCode().equals(redisUtils.get(Constants.DANGER_BIZ_TYPE_KEY))) { if (LatentDangerBizTypeEnum.防火监督.getCode().equals(redisUtils.get(Constants.DANGER_BIZ_TYPE_KEY))) {
// 防火监督业务 // 防火监督业务
executeSupervisionBiz(param, latentDanger, userId, userRealName, departmentId, departmentName, executeSupervisionBiz(param, latentDanger, userId, userRealName, departmentId, departmentName,
executeSubmitDto, role); executeSubmitDto, reginParams);
} else if (LatentDangerBizTypeEnum.巡检.getCode().equals(redisUtils.get(Constants.DANGER_BIZ_TYPE_KEY))) { } else if (LatentDangerBizTypeEnum.巡检.getCode().equals(redisUtils.get(Constants.DANGER_BIZ_TYPE_KEY))) {
// 巡检业务 // 巡检业务
executePatrolBiz(param, latentDanger, userId, userRealName, departmentId, departmentName, executePatrolBiz(param, latentDanger, userId, userRealName, departmentId, departmentName,
executeSubmitDto, role); executeSubmitDto, reginParams);
} }
return executeSubmitDto; return executeSubmitDto;
} }
private DangerExecuteSubmitDto executeSupervisionBiz(LatentDangerExecuteParam param, LatentDanger latentDanger, String userId, String userRealName, String departmentId, String departmentName, DangerExecuteSubmitDto executeSubmitDto, RoleBo role) throws Exception { private DangerExecuteSubmitDto executeSupervisionBiz(LatentDangerExecuteParam param, LatentDanger latentDanger,
String userId, String userRealName, String departmentId,
String departmentName,
DangerExecuteSubmitDto executeSubmitDto,
ReginParams reginParams) throws Exception {
// TODO 查询隐患的巡查信息 // TODO 查询隐患的巡查信息
JSONObject bizInfo = JSONObject.parseObject(latentDanger.getBizInfo()); JSONObject bizInfo = JSONObject.parseObject(latentDanger.getBizInfo());
if (ValidationUtil.isEmpty(bizInfo)) { if (ValidationUtil.isEmpty(bizInfo)) {
...@@ -1141,7 +1166,10 @@ public class LatentDangerServiceImpl extends BaseService<LatentDangerBo, LatentD ...@@ -1141,7 +1166,10 @@ public class LatentDangerServiceImpl extends BaseService<LatentDangerBo, LatentD
latentDanger.setDangerState(LatentDangerState.SupervisionDangerStateEnum.现场确认.getCode()); latentDanger.setDangerState(LatentDangerState.SupervisionDangerStateEnum.现场确认.getCode());
latentDanger.setDangerStateName(LatentDangerState.SupervisionDangerStateEnum.现场确认.getName()); latentDanger.setDangerStateName(LatentDangerState.SupervisionDangerStateEnum.现场确认.getName());
// 保存日志信息 // 保存日志信息
record = saveFlowRecord("", latentDanger.getDangerStateName(), userId, departmentId, null, latentDanger.getId(), role, "", ""); record = saveFlowRecord("", latentDanger.getDangerStateName(), userId, departmentId, null,
latentDanger.getId(), reginParams.getRole(),
latentDanger.getDangerStateName() + ExecuteTypeEnum.通过.getName(), "",
userRealName, departmentName, latentDanger.getDangerState());
latentDanger.setCurrentFlowRecordId(record.getId()); latentDanger.setCurrentFlowRecordId(record.getId());
this.updateById(latentDanger); this.updateById(latentDanger);
...@@ -1157,15 +1185,19 @@ public class LatentDangerServiceImpl extends BaseService<LatentDangerBo, LatentD ...@@ -1157,15 +1185,19 @@ public class LatentDangerServiceImpl extends BaseService<LatentDangerBo, LatentD
} }
// 执行任务(带权限校验) // 执行任务(带权限校验)
Boolean executeResult = workflowExecuteService.CompleteTask(processInstanceId, condition); // Boolean executeResult = workflowExecuteService.CompleteTask(processInstanceId, condition, reginParams);
// 校验权限
Boolean executeResult = workflowExecuteService.excuteTask(processInstanceId, condition);
if (!executeResult) { if (!executeResult) {
executeSubmitDto.setIsOk(false); executeSubmitDto.setIsOk(false);
executeResultMsg = "任务执行失败"; executeResultMsg = "任务执行失败";
} }
String nextState = ""; String nextState = "";
String nextStateName = ""; String nextStateName = "";
if (ExecuteTypeEnum.通过.getCode() == param.getExecuteType()) { if (ExecuteTypeEnum.通过.getCode().equals(param.getExecuteType())) {
// 执行成功更新隐患状态 // 执行成功更新隐患状态
LatentDangerState.SupervisionDangerStateEnum nextStateEnum = LatentDangerState.SupervisionDangerStateEnum nextStateEnum =
LatentDangerState.SupervisionDangerStateEnum.getEnumByCode(currentStateEnum.getNext()); LatentDangerState.SupervisionDangerStateEnum.getEnumByCode(currentStateEnum.getNext());
...@@ -1184,21 +1216,23 @@ public class LatentDangerServiceImpl extends BaseService<LatentDangerBo, LatentD ...@@ -1184,21 +1216,23 @@ public class LatentDangerServiceImpl extends BaseService<LatentDangerBo, LatentD
LatentDangerState.SupervisionDangerStateEnum.getEnumByCode(currentStateEnum.getRejectNext()); LatentDangerState.SupervisionDangerStateEnum.getEnumByCode(currentStateEnum.getRejectNext());
nextState = nextStateEnum.getCode(); nextState = nextStateEnum.getCode();
nextStateName = nextStateEnum.getName(); nextStateName = nextStateEnum.getName();
executeResultMsg = nextStateName + "拒绝"; executeResultMsg = nextStateName + ExecuteTypeEnum.驳回.getName();
} }
latentDanger.setDangerState(nextState); latentDanger.setDangerState(nextState);
latentDanger.setDangerStateName(nextStateName); latentDanger.setDangerStateName(nextStateName);
if (LatentDangerState.SupervisionDangerStateEnum.整改检查分管领导确认.getCode().equals(currentDangerState) if (ExecuteTypeEnum.通过.getCode().equals(param.getExecuteType()) &&
|| LatentDangerState.SupervisionDangerStateEnum.整改二次审核确认.getCode().equals(currentDangerState)) { (LatentDangerState.SupervisionDangerStateEnum.整改检查分管领导确认.getCode().equals(currentDangerState)
|| LatentDangerState.SupervisionDangerStateEnum.整改二次审核确认.getCode().equals(currentDangerState))) {
latentDanger.setDangerState(LatentDangerState.SupervisionDangerStateEnum.整改完毕.getCode()); latentDanger.setDangerState(LatentDangerState.SupervisionDangerStateEnum.整改完毕.getCode());
latentDanger.setDangerStateName(LatentDangerState.SupervisionDangerStateEnum.整改完毕.getName()); latentDanger.setDangerStateName(LatentDangerState.SupervisionDangerStateEnum.整改完毕.getName());
executeResultMsg = latentDanger.getDangerStateName(); executeResultMsg = latentDanger.getDangerStateName() + ExecuteTypeEnum.通过.getName();
} }
record = saveFlowRecord("", latentDanger.getDangerStateName(), userId, departmentId, null, latentDanger.getId(), role, record = saveFlowRecord("", latentDanger.getDangerStateName(), userId, departmentId, null,
executeResultMsg, ""); latentDanger.getId(), reginParams.getRole(), executeResultMsg, "", userRealName, departmentName,
latentDanger.getDangerState());
latentDanger.setCurrentFlowRecordId(record.getId()); latentDanger.setCurrentFlowRecordId(record.getId());
this.updateById(latentDanger); this.updateById(latentDanger);
...@@ -1208,7 +1242,10 @@ public class LatentDangerServiceImpl extends BaseService<LatentDangerBo, LatentD ...@@ -1208,7 +1242,10 @@ public class LatentDangerServiceImpl extends BaseService<LatentDangerBo, LatentD
return executeSubmitDto; return executeSubmitDto;
} }
private DangerExecuteSubmitDto executePatrolBiz(LatentDangerExecuteParam param, LatentDanger latentDanger, String userId, String userRealName, String departmentId, String departmentName, DangerExecuteSubmitDto executeSubmitDto, RoleBo role) { private DangerExecuteSubmitDto executePatrolBiz(LatentDangerExecuteParam param, LatentDanger latentDanger,
String userId, String userRealName, String departmentId,
String departmentName,DangerExecuteSubmitDto executeSubmitDto,
ReginParams reginParams) {
if (StringUtil.isNotEmpty(param.getReformLimitDate())) { if (StringUtil.isNotEmpty(param.getReformLimitDate())) {
param.setReformLimitDate(param.getReformLimitDate() + " 23:59:59"); param.setReformLimitDate(param.getReformLimitDate() + " 23:59:59");
} }
...@@ -1253,14 +1290,17 @@ public class LatentDangerServiceImpl extends BaseService<LatentDangerBo, LatentD ...@@ -1253,14 +1290,17 @@ public class LatentDangerServiceImpl extends BaseService<LatentDangerBo, LatentD
if (executeTypeEnum.getNextState().equals(LatentDangerStateEnum.已撤销)) { if (executeTypeEnum.getNextState().equals(LatentDangerStateEnum.已撤销)) {
latentDanger.setDangerState(executeTypeEnum.getNextState().getCode()); latentDanger.setDangerState(executeTypeEnum.getNextState().getCode());
saveFlowRecord(executeJson.getString("id"), data.getString("name"), userId, departmentId, saveFlowRecord(executeJson.getString("id"), data.getString("name"), userId, departmentId,
param.getFlowJson(), param.getDangerId(), role, executeTypeEnum.getName(), param.getRemark()); param.getFlowJson(), param.getDangerId(), reginParams.getRole(), executeTypeEnum.getName(),
param.getRemark(), userRealName, departmentName, latentDanger.getDangerState());
} else if (executeTypeEnum.getNextState().equals(LatentDangerStateEnum.治理完毕)) { } else if (executeTypeEnum.getNextState().equals(LatentDangerStateEnum.治理完毕)) {
latentDanger.setDangerState(executeTypeEnum.getNextState().getCode()); latentDanger.setDangerState(executeTypeEnum.getNextState().getCode());
saveFlowRecord(executeJson.getString("id"), data.getString("name"), userId, departmentId, saveFlowRecord(executeJson.getString("id"), data.getString("name"), userId, departmentId,
param.getFlowJson(), param.getDangerId(), role, executeTypeEnum.getName(), param.getRemark()); param.getFlowJson(), param.getDangerId(), reginParams.getRole(), executeTypeEnum.getName(),
param.getRemark(), userRealName, departmentName, latentDanger.getDangerState());
} else { } else {
LatentDangerFlowRecord flowRecord = saveFlowRecord(executeJson.getString("id"), data.getString("name"), userId, departmentId, LatentDangerFlowRecord flowRecord = saveFlowRecord(executeJson.getString("id"), data.getString("name"), userId, departmentId,
param.getFlowJson(), param.getDangerId(), role, executeTypeEnum.getName(), param.getRemark()); param.getFlowJson(), param.getDangerId(), reginParams.getRole(), executeTypeEnum.getName(),
param.getRemark(), userRealName, departmentName, latentDanger.getDangerState());
latentDanger.setCurrentFlowRecordId(flowRecord.getId()); latentDanger.setCurrentFlowRecordId(flowRecord.getId());
latentDanger.setDangerState(executeTypeEnum.getNextState().getCode()); latentDanger.setDangerState(executeTypeEnum.getNextState().getCode());
if (executeTypeEnum.equals(LatentDangerExecuteTypeEnum.隐患常规治理)) { if (executeTypeEnum.equals(LatentDangerExecuteTypeEnum.隐患常规治理)) {
......
...@@ -4,6 +4,7 @@ import java.util.List; ...@@ -4,6 +4,7 @@ import java.util.List;
import java.util.Map; import java.util.Map;
import com.baomidou.mybatisplus.core.metadata.IPage; import com.baomidou.mybatisplus.core.metadata.IPage;
import com.yeejoin.amos.boot.biz.common.bo.ReginParams;
import com.yeejoin.amos.feign.systemctl.model.DictionarieValueModel; import com.yeejoin.amos.feign.systemctl.model.DictionarieValueModel;
import com.yeejoin.amos.latentdanger.business.param.LatentDangerDto; import com.yeejoin.amos.latentdanger.business.param.LatentDangerDto;
import com.yeejoin.amos.latentdanger.business.param.LatentDangerExecuteParam; import com.yeejoin.amos.latentdanger.business.param.LatentDangerExecuteParam;
...@@ -55,7 +56,7 @@ public interface ILatentDangerService { ...@@ -55,7 +56,7 @@ public interface ILatentDangerService {
* @return * @return
*/ */
DangerExecuteSubmitDto execute(LatentDangerExecuteParam latentDangerExecuteParam, String userId, DangerExecuteSubmitDto execute(LatentDangerExecuteParam latentDangerExecuteParam, String userId,
String userRealName, String departmentId, String departmentName, RoleBo role) throws Exception; String userRealName, String departmentId, String departmentName, ReginParams reginParams) throws Exception;
ResponseModel<LatentDangerDetailVo> detail(Long dangerId, String userId, boolean isFinish) throws Exception; ResponseModel<LatentDangerDetailVo> detail(Long dangerId, String userId, boolean isFinish) throws Exception;
......
...@@ -31,6 +31,8 @@ public class LatentDangerDetailVo { ...@@ -31,6 +31,8 @@ public class LatentDangerDetailVo {
private Date reformLimitDate; private Date reformLimitDate;
private String reformLimitDateStr;
private JSONObject reformJson; private JSONObject reformJson;
private Long currentFlowRecordId; private Long currentFlowRecordId;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment