分解单加字段!! 标准评估流程 数据补充
This commit is contained in:
@@ -106,6 +106,13 @@
|
||||
<artifactId>activiti-modeler</artifactId>
|
||||
<version>${activiti.version}</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>net.sf.json-lib</groupId>
|
||||
<artifactId>json-lib</artifactId>
|
||||
<version>2.4</version>
|
||||
<classifier>jdk15</classifier>
|
||||
</dependency>
|
||||
<!-- <dependency>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-configuration-processor</artifactId>
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
* Copyright 2021 bejson.com
|
||||
*/
|
||||
package com.ydw.bat.wkflow.business_main.datas.dto;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import lombok.Data;
|
||||
|
||||
import java.util.Date;
|
||||
@@ -25,6 +26,10 @@ public class BreakdownList {
|
||||
private String busStandCover;
|
||||
private String responsibleUnit;
|
||||
private String responsibleEngineer;
|
||||
@JsonFormat( pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date xcxssrq;
|
||||
@JsonFormat( pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date zccssrq;
|
||||
public void setId(String id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
package com.ydw.bat.wkflow.business_main.datas.dto;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import lombok.Data;
|
||||
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
@Data
|
||||
@@ -32,8 +34,10 @@ public class PEPDTO {
|
||||
private String workPeople;
|
||||
//在研在产字段!!! 待定中 下发落实人需要使用
|
||||
//时间字段
|
||||
private String ZCCSSRQ;
|
||||
private String XCXSSRQ;
|
||||
@JsonFormat( pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date ZCCSSRQ;
|
||||
@JsonFormat( pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date XCXSSRQ;
|
||||
|
||||
private String commentText;
|
||||
|
||||
|
||||
@@ -29,93 +29,71 @@ public class SarStandItems {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty(value = "主键")
|
||||
@TableId("ID")
|
||||
private String id;
|
||||
|
||||
@ApiModelProperty(value = "标准ID")
|
||||
@TableField("STAND_ID")
|
||||
private String standId;
|
||||
|
||||
@ApiModelProperty(value = "条目编号")
|
||||
@TableField("ITEMS_NUM")
|
||||
private String itemsNum;
|
||||
|
||||
@ApiModelProperty(value = "条目内容")
|
||||
@TableField("ITEMS_NAME")
|
||||
private String itemsName;
|
||||
|
||||
@ApiModelProperty(value = "涉及零部件")
|
||||
@TableField("PARTS")
|
||||
private String parts;
|
||||
|
||||
@ApiModelProperty(value = "特殊生效时间")
|
||||
@TableField("TACK_TIME")
|
||||
@JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd")
|
||||
private Date tackTime;
|
||||
|
||||
@ApiModelProperty(value = "适用车型")
|
||||
@TableField("APPLY_ARCTIC")
|
||||
private String applyArctic;
|
||||
|
||||
@ApiModelProperty(value = "能源类型")
|
||||
@TableField("ENERGY_KIND")
|
||||
private String energyKind;
|
||||
|
||||
@ApiModelProperty(value = "责任部门")
|
||||
@TableField("RESPONSIBLE_UNIT")
|
||||
private String responsibleUnit;
|
||||
|
||||
@ApiModelProperty(value = "备注")
|
||||
@TableField("REMARKS")
|
||||
private String remarks;
|
||||
|
||||
@ApiModelProperty(value = "是否有效")
|
||||
@TableField("VALID_FLAG")
|
||||
private Integer validFlag;
|
||||
|
||||
@TableField("CREATION_USER")
|
||||
private String creationUser;
|
||||
|
||||
@ApiModelProperty(value = "创建时间")
|
||||
@TableField("CREATION_TIME")
|
||||
@JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date creationTime;
|
||||
|
||||
@ApiModelProperty(value = "修改时间")
|
||||
@TableField("MODIFY_TIME")
|
||||
@JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date modifyTime;
|
||||
|
||||
@ApiModelProperty(value = "条款要求")
|
||||
@TableField("TERMS_CONDITIONS")
|
||||
private String termsConditions;
|
||||
|
||||
@ApiModelProperty(value = "实施要点")
|
||||
@TableField("MAINPOINTS_IMPEMENTATION")
|
||||
private String mainpointsImpementation;
|
||||
|
||||
@ApiModelProperty(value = "FO")
|
||||
@TableField("FO")
|
||||
private String fo;
|
||||
|
||||
@ApiModelProperty(value = "责任工程师")
|
||||
@TableField("DUTY_ENGINEER")
|
||||
private String dutyEngineer;
|
||||
|
||||
@ApiModelProperty(value = "SVPPS")
|
||||
@TableField("SVPPS")
|
||||
private String svpps;
|
||||
|
||||
@ApiModelProperty(value = "要求类型")
|
||||
@TableField("CLAIM_TYPE")
|
||||
private String claimType;
|
||||
|
||||
@ApiModelProperty(value = "企标覆盖关系")
|
||||
@TableField("BUS_STAND_COVER")
|
||||
private String busStandCover;
|
||||
|
||||
@ApiModelProperty(value = "文件类型")
|
||||
@TableField("FILE_TYPE")
|
||||
private String fileType;
|
||||
|
||||
@ApiModelProperty(value = "新车型实施日期")
|
||||
@@ -126,7 +104,11 @@ public class SarStandItems {
|
||||
@JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date zccssrq;
|
||||
|
||||
@ApiModelProperty(value = "相对于上一版本变化点")
|
||||
private String comparedWithPrevious;
|
||||
|
||||
@ApiModelProperty(value = "合规性分析")
|
||||
private String complianceState;
|
||||
|
||||
|
||||
}
|
||||
|
||||
+1
@@ -211,5 +211,6 @@ public class PCAdlApproveAfter implements TaskListener {
|
||||
busBean.save(busProcessNewNext);
|
||||
}
|
||||
}
|
||||
throw new ActivitiException("sasaa");
|
||||
}
|
||||
}
|
||||
|
||||
+8
-4
@@ -11,8 +11,10 @@ import com.ydw.bat.wkflow.business_main.datas.entity.Datas;
|
||||
import com.ydw.bat.wkflow.business_main.datas.service.IBusProcessNameService;
|
||||
import com.ydw.bat.wkflow.business_main.datas.service.IBusProcessNewService;
|
||||
import com.ydw.bat.wkflow.business_main.datas.service.IDatasService;
|
||||
import com.ydw.bat.wkflow.util.DealWithDate;
|
||||
import com.ydw.bat.wkflow.util.JsonDateValueProcessor;
|
||||
import com.ydw.bat.wkflow.util.SpringContextUtil;
|
||||
import org.activiti.engine.ActivitiException;
|
||||
import net.sf.json.JsonConfig;
|
||||
import org.activiti.engine.delegate.DelegateTask;
|
||||
import org.activiti.engine.delegate.TaskListener;
|
||||
import org.springframework.beans.BeanUtils;
|
||||
@@ -104,8 +106,10 @@ public class PEPmanagerApproveAfter implements TaskListener {
|
||||
res.setUname(da.getUname());
|
||||
res.setProjectManager(da.getProjectManager());
|
||||
//时间
|
||||
res.setXCXSSRQ(String.valueOf(delegateTask.getVariable("XCXSSRQ")));
|
||||
res.setZCCSSRQ(String.valueOf(delegateTask.getVariable("ZCCSSRQ")));
|
||||
// res.setXCXSSRQ(String.valueOf(delegateTask.getVariable("XCXSSRQ")));
|
||||
res.setXCXSSRQ(breakdownList1.getXcxssrq());
|
||||
// res.setZCCSSRQ(String.valueOf(delegateTask.getVariable("ZCCSSRQ")));
|
||||
res.setZCCSSRQ(breakdownList1.getZccssrq());
|
||||
pepdtos.add(res);
|
||||
}
|
||||
}
|
||||
@@ -139,7 +143,7 @@ public class PEPmanagerApproveAfter implements TaskListener {
|
||||
BusProcessNew busProcessNewNext = new BusProcessNew();
|
||||
busProcessNewNext.setMsgType("clause");
|
||||
busProcessNewNext.setPId(delegateTask.getProcessInstanceId());
|
||||
busProcessNewNext.setMesg(JSONObject.toJSONString(map.get(liable)));
|
||||
busProcessNewNext.setMesg(DealWithDate.delWithTime(map.get(liable)));
|
||||
busProcessNewNext.setTaskInfo(delegateTask.getTaskDefinitionKey());
|
||||
busProcessNewNext.setFinishFlag("0");
|
||||
busProcessNewNext.setTaskInfo(delegateTask.getName());
|
||||
|
||||
@@ -61,6 +61,8 @@ public class DeptApplayAfter implements TaskListener{
|
||||
sarStandItems1.setTermsConditions(object.getString("itermsConditions"));
|
||||
sarStandItems1.setXccssrq(os.getDate("newData"));
|
||||
sarStandItems1.setZccssrq(os.getDate("onlineData"));
|
||||
sarStandItems1.setComparedWithPrevious(os.getString("changePoint"));
|
||||
sarStandItems1.setComplianceState(os.getString("complianceState"));
|
||||
sarStandItems.add(sarStandItems1);
|
||||
//结果数据
|
||||
SarInterpretationNationalStandard standard=new SarInterpretationNationalStandard();
|
||||
|
||||
@@ -0,0 +1,18 @@
|
||||
package com.ydw.bat.wkflow.util;
|
||||
|
||||
import com.ydw.bat.wkflow.business_main.datas.dto.PEPres;
|
||||
import net.sf.json.JSONObject;
|
||||
import net.sf.json.JsonConfig;
|
||||
|
||||
import java.util.Date;
|
||||
|
||||
public class DealWithDate {
|
||||
|
||||
public static String delWithTime(PEPres a){
|
||||
JsonConfig jsonConfig = new JsonConfig();
|
||||
jsonConfig.registerJsonValueProcessor(Date.class, new JsonDateValueProcessor());
|
||||
JSONObject jsonObject = JSONObject.fromObject(a,jsonConfig);
|
||||
return jsonObject.toString();
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,41 @@
|
||||
package com.ydw.bat.wkflow.util;
|
||||
|
||||
import net.sf.json.JsonConfig;
|
||||
import net.sf.json.processors.JsonValueProcessor;
|
||||
|
||||
import java.text.SimpleDateFormat;
|
||||
import java.util.Date;
|
||||
|
||||
public class JsonDateValueProcessor implements JsonValueProcessor {
|
||||
|
||||
private String datePattern = "yyyy-MM-dd HH:mm:ss";//默认样式,可以在构造方法中修改
|
||||
public JsonDateValueProcessor() {
|
||||
super();
|
||||
}
|
||||
public JsonDateValueProcessor(String datePattern) {
|
||||
super();
|
||||
this.datePattern = datePattern;
|
||||
}
|
||||
public Object processArrayValue(Object value, JsonConfig jsonConfig) {
|
||||
try {
|
||||
if(value instanceof Date){
|
||||
SimpleDateFormat sdf = new SimpleDateFormat(datePattern);
|
||||
Date date = (Date)value;
|
||||
return sdf.format(date);
|
||||
}
|
||||
return value == null ? null : value.toString();
|
||||
} catch (Exception e) {
|
||||
return null;
|
||||
}
|
||||
}
|
||||
public Object processObjectValue(String key, Object value, JsonConfig jsonConfig) {
|
||||
return processArrayValue(value, jsonConfig);
|
||||
}
|
||||
public String getDatePattern() {
|
||||
return datePattern;
|
||||
}
|
||||
public void setDatePattern(String datePattern) {
|
||||
this.datePattern = datePattern;
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user