废止人、废止时间回填

This commit is contained in:
zhal 2024-08-27 16:09:03 +08:00
parent 482c51028f
commit da8800fe2b
2 changed files with 24 additions and 11 deletions

View File

@ -7,6 +7,9 @@ import com.actionsoft.apps.coe.pal.pal.output.extend.OutputAppProfile;
import com.actionsoft.apps.coe.pal.pal.output.model.OutputTaskModel;
import com.actionsoft.apps.coe.pal.pal.repository.dao.CoeProcessLevelDaoFacotory;
import com.actionsoft.apps.coe.pal.pal.repository.dao.PALRepositoryPropertyDao;
import com.actionsoft.apps.coe.pal.pal.repository.designer.relation.cache.DesignerShapeRelationCache;
import com.actionsoft.apps.coe.pal.pal.repository.designer.relation.dao.DesignerShapeRelationDao;
import com.actionsoft.apps.coe.pal.pal.repository.designer.relation.model.DesignerShapeRelationModel;
import com.actionsoft.apps.coe.pal.pal.repository.upfile.model.UpfileModel;
import com.actionsoft.apps.coe.pal.pal.repository.upfile.web.UpfileWeb;
import com.actionsoft.apps.coe.pal.system.util.StringUtil;
@ -231,23 +234,14 @@ public class UpateFileStateController {
PALRepositoryPropertyDao propertyDao = new PALRepositoryPropertyDao();
BO bo_act_coe_publish_s = SDK.getBOAPI().query("BO_ACT_COE_PUBLISH_S").addQuery("STOPFILEID=", plId).detail();
BO bo_act_coe_publish_n = SDK.getBOAPI().query("BO_ACT_COE_PUBLISH_N").addQuery("PUBLISHFILEID=", plId).detail();
String bindid=bo_act_coe_publish_s.getBindId();
String bindid=bo_act_coe_publish_n.getBindId();
BO publish = SDK.getBOAPI().query("BO_ACT_COE_PUBLISH").detailByBindId(bindid);
String sql = "insert into APP_ACT_COE_PAL_SHAPE_RLAT (ID,FILEID,ATTRID,RELATIONFILEID,RELATIONSHAPEID,RELATIONSHAPETEXT) values ('%s', '%s', '%s','%s','%s','%s')";
JSONObject js=new JSONObject();
js.put("name", publish.getString("APPLYUSERNAME"));
js.put("id", publish.getString("APPLYUSERID"));
js.put("type", "user");
String id = UUIDGener.getUUID();
int update = DBSql.update(String.format(sql, id, plId, "nullifier","00000000-0000-0000-0000-000000000000","00000000-0000-0000-0000-000000000000",js));
//作废时间
Date cancelDate=new Date();
SimpleDateFormat sdfs = new SimpleDateFormat("yyyy-MM-dd");
@ -255,6 +249,25 @@ public class UpateFileStateController {
PALRepositoryModel plModel = CoeProcessLevelDaoFacotory.createCoeProcessLevel().getInstance(plId);
if (plModel != null) {
DesignerShapeRelationModel designerShapeRelationModel=new DesignerShapeRelationModel();
designerShapeRelationModel.setId(UUIDGener.getUUID());
designerShapeRelationModel.setFileId(plId);
designerShapeRelationModel.setAttrId("nullifier");
designerShapeRelationModel.setRelationFileId("00000000-0000-0000-0000-000000000000");
designerShapeRelationModel.setRelationShapeId("00000000-0000-0000-0000-000000000000");
JSONObject js=new JSONObject();
js.put("name", publish.getString("APPLYUSERNAME"));
js.put("id", publish.getString("APPLYUSERID"));
js.put("type", "user");
designerShapeRelationModel.setRelationShapeText(js.toString());
DesignerShapeRelationDao dao = new DesignerShapeRelationDao();
dao.insert(designerShapeRelationModel);
PALRepositoryCache.getCache().put(plId, plModel);
}