1.技术监督调整
This commit is contained in:
@@ -54,7 +54,7 @@ public class ThsSuperviseController extends BaseController {
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
@OperateInfo(info = LogEnum.BUSINESS_COMMON)
|
/* @OperateInfo(info = LogEnum.BUSINESS_COMMON)
|
||||||
@ApiOperation("预警/告警事务生成手动")
|
@ApiOperation("预警/告警事务生成手动")
|
||||||
@ApiImplicitParam(name = "superviseParam", value = "创建技术监督参数", required = true)
|
@ApiImplicitParam(name = "superviseParam", value = "创建技术监督参数", required = true)
|
||||||
@PostMapping("/initSuperviseHand")
|
@PostMapping("/initSuperviseHand")
|
||||||
@@ -63,7 +63,7 @@ public class ThsSuperviseController extends BaseController {
|
|||||||
SuperviceRunLogVo result = thsSuperviseService.initSuperviseHand(superviseParam);
|
SuperviceRunLogVo result = thsSuperviseService.initSuperviseHand(superviseParam);
|
||||||
return HttpResultUtil.assembleCommonResponseResult(CommonResponseEnum.SUCCESS, result, methodDescribe);
|
return HttpResultUtil.assembleCommonResponseResult(CommonResponseEnum.SUCCESS, result, methodDescribe);
|
||||||
}
|
}
|
||||||
|
*/
|
||||||
|
|
||||||
@OperateInfo(info = LogEnum.BUSINESS_COMMON)
|
@OperateInfo(info = LogEnum.BUSINESS_COMMON)
|
||||||
@ApiOperation("预警/告警事务生成自动")
|
@ApiOperation("预警/告警事务生成自动")
|
||||||
|
|||||||
@@ -116,7 +116,7 @@ public interface ThsSuperviseService extends IService<ThsSupervise> {
|
|||||||
SuperviceRunLogVo initSupervise(@RequestBody @Validated SuperviseParam superviseParam);
|
SuperviceRunLogVo initSupervise(@RequestBody @Validated SuperviseParam superviseParam);
|
||||||
|
|
||||||
|
|
||||||
SuperviceRunLogVo initSuperviseHand(@RequestBody @Validated SuperviseParam superviseParam);
|
//SuperviceRunLogVo initSuperviseHand(@RequestBody @Validated SuperviseParam superviseParam);
|
||||||
|
|
||||||
|
|
||||||
Page<ThsSupervise> queryPage(ThsSuperviseParam thsSuperviseParam);
|
Page<ThsSupervise> queryPage(ThsSuperviseParam thsSuperviseParam);
|
||||||
|
|||||||
@@ -26,6 +26,7 @@ import com.njcn.harmonic.pojo.vo.ThsStrategyVo;
|
|||||||
import com.njcn.oss.constant.OssPath;
|
import com.njcn.oss.constant.OssPath;
|
||||||
import com.njcn.oss.utils.FileStorageUtil;
|
import com.njcn.oss.utils.FileStorageUtil;
|
||||||
import com.njcn.prepare.harmonic.pojo.dto.SuperviseDto;
|
import com.njcn.prepare.harmonic.pojo.dto.SuperviseDto;
|
||||||
|
import com.njcn.process.api.FlowableDefineFeignClient;
|
||||||
import com.njcn.process.pojo.param.SuperviseParam;
|
import com.njcn.process.pojo.param.SuperviseParam;
|
||||||
import com.njcn.process.pojo.po.ThsOverRunLog;
|
import com.njcn.process.pojo.po.ThsOverRunLog;
|
||||||
import com.njcn.process.pojo.po.ThsSupervise;
|
import com.njcn.process.pojo.po.ThsSupervise;
|
||||||
@@ -95,9 +96,6 @@ import static com.njcn.process.enums.SteadyIndicatorEnum.Negative_Voltage;
|
|||||||
public class ThsSuperviseServiceImpl extends ServiceImpl<ThsSuperviseMapper, ThsSupervise> implements ThsSuperviseService {
|
public class ThsSuperviseServiceImpl extends ServiceImpl<ThsSuperviseMapper, ThsSupervise> implements ThsSuperviseService {
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
private final ThsWarnStrategyMapper thsWarnStrategyMapper;
|
private final ThsWarnStrategyMapper thsWarnStrategyMapper;
|
||||||
|
|
||||||
private final ThsWarnStrategyAssMapper thsWarnStrategyAssMapper;
|
private final ThsWarnStrategyAssMapper thsWarnStrategyAssMapper;
|
||||||
@@ -125,6 +123,8 @@ public class ThsSuperviseServiceImpl extends ServiceImpl<ThsSuperviseMapper, Ths
|
|||||||
|
|
||||||
private final FlowableAssMapper flowableAssMapper;
|
private final FlowableAssMapper flowableAssMapper;
|
||||||
|
|
||||||
|
private final IFlowDefinitionService flowDefinitionService;
|
||||||
|
|
||||||
private final ThsDeptMonitorMapper thsDeptMonitorMapper;
|
private final ThsDeptMonitorMapper thsDeptMonitorMapper;
|
||||||
|
|
||||||
private final CommTerminalGeneralClient commTerminalGeneralClient;
|
private final CommTerminalGeneralClient commTerminalGeneralClient;
|
||||||
@@ -411,8 +411,6 @@ public class ThsSuperviseServiceImpl extends ServiceImpl<ThsSuperviseMapper, Ths
|
|||||||
thsAlarmFormworkMapper.insert(alarmFormwork);
|
thsAlarmFormworkMapper.insert(alarmFormwork);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@@ -424,8 +422,11 @@ public class ThsSuperviseServiceImpl extends ServiceImpl<ThsSuperviseMapper, Ths
|
|||||||
throw new BusinessException("请先上传下发单模板单据!");
|
throw new BusinessException("请先上传下发单模板单据!");
|
||||||
}
|
}
|
||||||
String fileUrl = fileStorageUtil.getFileUrl(thsAlarmFormwork.getPath());
|
String fileUrl = fileStorageUtil.getFileUrl(thsAlarmFormwork.getPath());
|
||||||
|
|
||||||
|
|
||||||
ThsSupervise thsSupervise = new ThsSupervise();
|
ThsSupervise thsSupervise = new ThsSupervise();
|
||||||
thsSupervise.setModifyTime(new Date());
|
thsSupervise.setModifyTime(new Date());
|
||||||
|
thsSupervise.setModifyUser(RequestUtil.getUserIndex());
|
||||||
ThsOverRunLog thsOverRunLog = new ThsOverRunLog();
|
ThsOverRunLog thsOverRunLog = new ThsOverRunLog();
|
||||||
thsOverRunLog.setSupIndex(supIndex);
|
thsOverRunLog.setSupIndex(supIndex);
|
||||||
if (FormworkTypeEnum.ALARM_TICKET.getCode().equals(formworkType)) {
|
if (FormworkTypeEnum.ALARM_TICKET.getCode().equals(formworkType)) {
|
||||||
@@ -439,6 +440,7 @@ public class ThsSuperviseServiceImpl extends ServiceImpl<ThsSuperviseMapper, Ths
|
|||||||
thsOverRunLogService.update(thsOverRunLog, new LambdaQueryWrapper<ThsOverRunLog>().eq(ThsOverRunLog::getSupIndex, supIndex));
|
thsOverRunLogService.update(thsOverRunLog, new LambdaQueryWrapper<ThsOverRunLog>().eq(ThsOverRunLog::getSupIndex, supIndex));
|
||||||
thsSuperviseMapper.update(thsSupervise, new LambdaQueryWrapper<ThsSupervise>().eq(ThsSupervise::getSupIndex, supIndex));
|
thsSuperviseMapper.update(thsSupervise, new LambdaQueryWrapper<ThsSupervise>().eq(ThsSupervise::getSupIndex, supIndex));
|
||||||
|
|
||||||
|
|
||||||
FlowableAss flowableAss = flowableAssMapper.selectById(supIndex);
|
FlowableAss flowableAss = flowableAssMapper.selectById(supIndex);
|
||||||
Task task = iFlowTaskService.getTask(flowableAss.getExecIndex());
|
Task task = iFlowTaskService.getTask(flowableAss.getExecIndex());
|
||||||
|
|
||||||
@@ -565,9 +567,9 @@ public class ThsSuperviseServiceImpl extends ServiceImpl<ThsSuperviseMapper, Ths
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 生成预警单告警单(自动)
|
* 生成预警单告警单(自动)
|
||||||
|
*
|
||||||
* @author cdf
|
* @author cdf
|
||||||
* @date 2024/1/29
|
* @date 2024/1/29
|
||||||
*/
|
*/
|
||||||
@@ -660,6 +662,18 @@ public class ThsSuperviseServiceImpl extends ServiceImpl<ThsSuperviseMapper, Ths
|
|||||||
|
|
||||||
if (superviseParam.getInitType().equals(InitTypeEnum.AUTO.getCode())) {
|
if (superviseParam.getInitType().equals(InitTypeEnum.AUTO.getCode())) {
|
||||||
if (CollectionUtil.isNotEmpty(thsSuperviseListPO)) {
|
if (CollectionUtil.isNotEmpty(thsSuperviseListPO)) {
|
||||||
|
|
||||||
|
//处理flowable
|
||||||
|
for(ThsSupervise ths:thsSuperviseListPO){
|
||||||
|
Map<String, Object> mapParam = new HashMap<>();
|
||||||
|
String proInId = "";
|
||||||
|
if (ths.getType() == 0) {
|
||||||
|
proInId = "flow_yzep99kb:1:a100b48b-da75-11ed-8335-b07b253cdad9";
|
||||||
|
} else {
|
||||||
|
proInId = "flow_yzep99kb:2:6358e099-dcba-11ed-8026-b07b253cdad9";
|
||||||
|
}
|
||||||
|
flowDefinitionService.startProcessInstanceById(proInId, thsSupervise.getSupIndex(), mapParam);
|
||||||
|
}
|
||||||
this.saveBatch(thsSuperviseListPO);
|
this.saveBatch(thsSuperviseListPO);
|
||||||
thsOverRunLogService.saveBatch(allThsLogPO);
|
thsOverRunLogService.saveBatch(allThsLogPO);
|
||||||
return null;
|
return null;
|
||||||
@@ -670,7 +684,6 @@ public class ThsSuperviseServiceImpl extends ServiceImpl<ThsSuperviseMapper, Ths
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -680,7 +693,7 @@ public class ThsSuperviseServiceImpl extends ServiceImpl<ThsSuperviseMapper, Ths
|
|||||||
return superviceRunLogVo;
|
return superviceRunLogVo;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
/*@Override
|
||||||
public SuperviceRunLogVo initSuperviseHand(SuperviseParam superviseParam) {
|
public SuperviceRunLogVo initSuperviseHand(SuperviseParam superviseParam) {
|
||||||
SuperviceRunLogVo superviceRunLogVo = new SuperviceRunLogVo();
|
SuperviceRunLogVo superviceRunLogVo = new SuperviceRunLogVo();
|
||||||
List<ThsOverRunLog> thsOverRunLogList = new ArrayList<>();
|
List<ThsOverRunLog> thsOverRunLogList = new ArrayList<>();
|
||||||
@@ -704,7 +717,6 @@ public class ThsSuperviseServiceImpl extends ServiceImpl<ThsSuperviseMapper, Ths
|
|||||||
Dept dept = deptFeignClient.getDeptById(oneStrategyVo.getDeptId()).getData();
|
Dept dept = deptFeignClient.getDeptById(oneStrategyVo.getDeptId()).getData();
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
List<ThsWarnStrategyAss> oneInterferenceSourceAsses = this.queryWarnStrategyAss(oneStrategyVo.getId(), TypeEnum.SOURCE_TYPE);//干扰源列表
|
List<ThsWarnStrategyAss> oneInterferenceSourceAsses = this.queryWarnStrategyAss(oneStrategyVo.getId(), TypeEnum.SOURCE_TYPE);//干扰源列表
|
||||||
List<ThsWarnStrategyAss> oneSteadyIndicatorAsses = this.queryWarnStrategyAss(oneStrategyVo.getId(), TypeEnum.INTERFERENCE_TYPE);//指标类型列表
|
List<ThsWarnStrategyAss> oneSteadyIndicatorAsses = this.queryWarnStrategyAss(oneStrategyVo.getId(), TypeEnum.INTERFERENCE_TYPE);//指标类型列表
|
||||||
List<ThsWarnStrategyAss> oneMonitorAsses = this.queryWarnStrategyAss(oneStrategyVo.getId(), TypeEnum.MONITOR_TYPE);//监测点列表
|
List<ThsWarnStrategyAss> oneMonitorAsses = this.queryWarnStrategyAss(oneStrategyVo.getId(), TypeEnum.MONITOR_TYPE);//监测点列表
|
||||||
@@ -770,7 +782,7 @@ public class ThsSuperviseServiceImpl extends ServiceImpl<ThsSuperviseMapper, Ths
|
|||||||
}
|
}
|
||||||
superviceRunLogVo.setOverRunLog(thsOverRunLogList);
|
superviceRunLogVo.setOverRunLog(thsOverRunLogList);
|
||||||
return superviceRunLogVo;
|
return superviceRunLogVo;
|
||||||
}
|
}*/
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public Page<ThsSupervise> queryPage(ThsSuperviseParam thsSuperviseParam) {
|
public Page<ThsSupervise> queryPage(ThsSuperviseParam thsSuperviseParam) {
|
||||||
@@ -815,8 +827,6 @@ public class ThsSuperviseServiceImpl extends ServiceImpl<ThsSuperviseMapper, Ths
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 批量下载.zip文件
|
* 批量下载.zip文件
|
||||||
*
|
*
|
||||||
|
|||||||
Reference in New Issue
Block a user