Merge branch 'develop_migration' into 'develop_master'

feat: There is no way the, 企标审批完入库后,入库人应为流程发起人

See merge request LiuChao/foton-slrs-system-rest!410
This commit is contained in:
super_liu
2022-03-03 16:08:21 +08:00
5 changed files with 21 additions and 3 deletions
@@ -225,6 +225,7 @@ public class ActSarItemsBussEOService {
String prcNum = String.valueOf(standMap.get("prcNum"));
String pid = String.valueOf(standMap.get("topId"));
String prcName = String.valueOf(standMap.get("prcName"));
String prcCreateUser = String.valueOf(standMap.get("prcCreateUser"));
String standType = String.valueOf(standMap.get("standType"));
// String isJudge = String.valueOf(standMap.get("ifIn")); //是否经过技术评估
SarBussionessStand sarBussionessStand = new SarBussionessStand();
@@ -316,7 +317,7 @@ public class ActSarItemsBussEOService {
// 编辑相关流程
sarBussStandAttrInfoService.updateStandInfo(sarBussionessStand.getId(),"XGLC",relatePro);
String content = "新增一条相关流程:" +prcName+" "+prcNum;
sarUpdLogEOService.createBaseLog(sarBussionessStand.getId(),standType+"_STAND",content);
sarUpdLogEOService.createBaseProcessLog(sarBussionessStand.getId(),"BUSINESS",content,prcCreateUser);
}else if (lawsList != null && !lawsList.isEmpty()) {//Id不存在,但是标准号存在的情况
String standId = lawsList.get(0).getId();
bussId = lawsList.get(0).getId();
@@ -348,9 +349,10 @@ public class ActSarItemsBussEOService {
// 编辑相关流程
sarBussStandAttrInfoService.updateStandInfo(standId,"XGLC",relatePro);
String content = "新增一条相关流程:" +prcName+" "+prcNum;
sarUpdLogEOService.createBaseLog(standId,standType+"_STAND",content);
sarUpdLogEOService.createBaseProcessLog(standId,"BUSINESS",content,prcCreateUser);
} else {//标准号、ID都不存在的情况
// 新增方法
sarBussionessStand.setPrcCreateUser(prcCreateUser);
ResponseMessage<SarBussionessStand> responseMessage = iSarBussionessStandService.createSarBussionessStand(sarBussionessStand);
if(responseMessage.isOk()){
SarBussionessStand bussionessStand = responseMessage.getData();
@@ -232,6 +232,8 @@ public class SarBussionessStand extends BaseEntity {
private String issueTimeStart;
@TableField(exist = false)
private String issueTimeEnd;
@TableField(exist = false)
private String prcCreateUser;
public static long getSerialVersionUID() {
return serialVersionUID;
@@ -231,7 +231,8 @@ public class SarBussionessStandServiceImpl extends ServiceImpl<SarBussionessStan
number += "-" + sarBussionessStandEO.getStandYear();
}
String content = "入库" + number + "" + sarBussionessStandEO.getStandName() + "";
sarUpdLogEOService.createBaseLog(sarBussionessStandEO.getId(),"BUSINESS",content);
String prcCreateUser = StringUtils.isNotBlank(sarBussionessStandEO.getPrcCreateUser()) ? sarBussionessStandEO.getPrcCreateUser() : "";
sarUpdLogEOService.createBaseProcessLog(sarBussionessStandEO.getId(),"BUSINESS",content,prcCreateUser);
if(elasflag) {
attrInfoShowSearchDetails(sarBussionessStandEO,"add");
createStandMQService.sendBussStandMQ(sarBussionessStandEO,"add");
@@ -21,5 +21,7 @@ public interface ISarUpdLogService extends IService<SarUpdLog> {
void createBaseLog(String sarId, String sarType, String content) throws Exception;
void createBaseProcessLog(String sarId, String sarType, String content,String user) throws Exception;
void createUpdateLog(String sarType, String sarId, Map<String, Object> oldMap, Map<String, Object> newMap, String standContent) throws Exception;
}
@@ -266,4 +266,15 @@ public class SarUpdLogServiceImpl extends ServiceImpl<SarUpdLogDao, SarUpdLog> i
dao.insert(sarUpdLogEO);
}
public void createBaseProcessLog (String sarId,String sarType,String content,String user) throws Exception {
SarUpdLog sarUpdLogEO = new SarUpdLog();
sarUpdLogEO.setId(UUIDUtils.randomUUID20());
sarUpdLogEO.setSarId(sarId);
sarUpdLogEO.setSarType(sarType);
sarUpdLogEO.setCreationTime(new Date());
sarUpdLogEO.setCreationUser(StringUtils.isNotBlank(user) ? user : (LoginUserUtil.getUserId() == null ? "" : LoginUserUtil.getUserId()));
sarUpdLogEO.setContent(content);
dao.insert(sarUpdLogEO);
}
}