cad9fde2 张雷

禅道BUG修改

1 个父辈 378fb5a4
package com.skua.common.constant;
/**
* 报表缓存常量
*/
public interface ReportConstant {
//水质水量报表
public static final String view2119 = "2119ecbf53a1d2d0708258ff67cfd9e1";
public static final String view3a24 = "3a243d5715b9e1a3753c180872ca0df9";
public static final String view4411 = "4411ed3d78634bcdcd700f6e33724025";
//化验日报
public static final String view9bff = "9bffaf9187093d6e6a4390e8c56acca8";
}
......@@ -235,7 +235,7 @@ public class DangerousOperationController {
dangerousOperationService.updateById(dangerOperation);
//流程进入下一节点,并行网关设置判定条件
Map<String, Object> mapVariable = new HashMap<String,Object>();
mapVariable.put("dangerDeal", "taskUser_"+dangerousOperation.getOperationUser());
mapVariable.put("dangerDeal", "taskUser_"+dangerousOperation.getAppointUser());
flowService.configureVariables(executionId, mapVariable);
//动态设置流程接收人
flowBusinessService.completeTask(ProcessConstant.PASS_KEY, dangerousOperation.getFlow());
......
......@@ -145,4 +145,8 @@ public class DangerousOperation extends FlowEntity {
@TableField(exist = false)
@ApiModelProperty(value = "结束时间")
private String endTime;
@TableField(exist = false)
@ApiModelProperty(value = "指定人")
private String appointUser;
}
......
package com.skua.modules.job;
import com.skua.common.constant.ReportConstant;
import com.skua.core.context.SpringContextUtils;
import com.skua.core.util.DateUtils;
import com.skua.modules.report.service.IReportDataService;
......@@ -23,15 +24,23 @@ public class NFDataSyncJob implements Job {
@Autowired
private IReportDataService reportDataService;
//水质水量报表
private static final String SZSL = "2119ecbf53a1d2d0708258ff67cfd9e1";
//化验日报
private static final String HYRB = "9bffaf9187093d6e6a4390e8c56acca8";
/**
* 若参数变量名修改 QuartzJobController中也需对应修改
*/
private String parameter;
public void setParameter(String parameter) {
this.parameter = parameter;
}
@Override
public void execute(JobExecutionContext jobExecutionContext) {
log.info("开始同步昨日恩菲的数据入报表");
String yesterday = DateUtils.getYesterday();
if(StringUtils.isNotEmpty(this.parameter)){
yesterday = this.parameter;
}
log.info("开始同步【"+yesterday+"】恩菲的数据入报表");
JdbcTemplate nfDb = (JdbcTemplate) SpringContextUtils.getBean("nf-db");
String sql = "select * from day_report_data where update_time like '"+yesterday+"%'";
List<Map<String, Object>> dataList = nfDb.queryForList(sql);
......@@ -47,23 +56,23 @@ public class NFDataSyncJob implements Job {
data.put("time",yesterday);
if("szsl".equals(itemType)){
data.put(itemCode, itemValue);
data.put("reportId", SZSL);
reportDataService.insertOrUpdateReportData(departId, time, data, SZSL);
data.put("reportId", ReportConstant.view2119);
reportDataService.insertOrUpdateReportData(departId, time, data, ReportConstant.view2119);
}else if("hyrb".equals(itemType)){
String indexs = "JSCOD,JSAD,JSPH,JSZD,JSZL,JSSS,CSCOD,CSAD,CSPH,CSTN,CSZL,CSSS";
if(itemCode.indexOf(indexs) > 0){
if(indexs.indexOf(itemCode) > 0){
data.put(itemCode+"HY", itemValue);
}else{
data.put(itemCode, itemValue);
}
data.put("reportId", HYRB);
reportDataService.insertOrUpdateReportData(departId, time, data, HYRB);
data.put("reportId", ReportConstant.view9bff);
reportDataService.insertOrUpdateReportData(departId, time, data, ReportConstant.view9bff);
}else {
log.info("恩菲【"+itemType+"】类型数据未进行数据同步");
}
}
}
log.info("同步昨日恩菲的数据入报表完成");
log.info("恩菲的数据入报表完成");
}
}
......
支持 Markdown 格式
你添加了 0 到此讨论。请谨慎行事。
Finish editing this message first!