Merge branch 'fix_bug_first_stage'
# Conflicts: # jero-web/src/common/lang/en-us.js # jero-web/src/common/lang/zh-cn.js # jero-web/src/views/documentTools/virtualList/components/virtualListDetails.vue # jero-web/src/views/projectManagement/components/listOfRegulations.vue
This commit is contained in:
+14
-14
@@ -236,11 +236,11 @@ public class DummyInventoryInfoEOServiceImpl extends ServiceImpl<DummyInventoryI
|
||||
List<Map<String,String>> infoDiffListEn = new ArrayList<>();
|
||||
infoDiffListEn.add(infoDiffEn);
|
||||
if(infoDiff.size()>1) {
|
||||
contentLog = dummyInventoryBaseEOService.setInfoDiffListContent(null, infoDiffList, contentLog);
|
||||
enContentLog = dummyInventoryBaseEOService.setInfoDiffListContent(enContentLog, infoDiffListEn, null);
|
||||
// contentLog = dummyInventoryBaseEOService.setInfoDiffListContent(null, infoDiffList, contentLog);
|
||||
// enContentLog = dummyInventoryBaseEOService.setInfoDiffListContent(enContentLog, infoDiffListEn, null);
|
||||
|
||||
dummyLogEOService.updateLog(contentLog, dummyInventoryInfoEO.getDummyInventoryBaseId(),CutEnum.CN.getValue());
|
||||
dummyLogEOService.updateLog(enContentLog, dummyInventoryInfoEO.getDummyInventoryBaseId(),CutEnum.EN.getValue());
|
||||
// dummyLogEOService.updateLog(contentLog, dummyInventoryInfoEO.getDummyInventoryBaseId(),CutEnum.CN.getValue());
|
||||
// dummyLogEOService.updateLog(enContentLog, dummyInventoryInfoEO.getDummyInventoryBaseId(),CutEnum.EN.getValue());
|
||||
}
|
||||
}else{
|
||||
if(CutEnum.CN.getValue().equals(dummyInventoryInfoEO.getCut())){
|
||||
@@ -362,14 +362,14 @@ public class DummyInventoryInfoEOServiceImpl extends ServiceImpl<DummyInventoryI
|
||||
this.saveBatch(dummyInventoryInfoEOList);
|
||||
|
||||
//更新log
|
||||
LoginUser sysUser = (LoginUser) SecurityUtils.getSubject().getPrincipal();
|
||||
String username = sysUser.getUsername();
|
||||
String projectId = dummyInventoryInfoEOList.get(0).getDummyInventoryBaseId();
|
||||
String serialNumber = dummyInventoryInfoEOList.stream().map(e->e.getSerialNumber()).collect(Collectors.joining(","));
|
||||
String contentLog = username+"复制了“"+serialNumber+"”";
|
||||
String enContentLog = username+" copied “"+serialNumber+"”.";
|
||||
dummyLogEOService.updateLog(contentLog, projectId,CutEnum.CN.getValue());
|
||||
dummyLogEOService.updateLog(enContentLog, projectId,CutEnum.EN.getValue());
|
||||
// LoginUser sysUser = (LoginUser) SecurityUtils.getSubject().getPrincipal();
|
||||
// String username = sysUser.getUsername();
|
||||
// String projectId = dummyInventoryInfoEOList.get(0).getDummyInventoryBaseId();
|
||||
// String serialNumber = dummyInventoryInfoEOList.stream().map(e->e.getSerialNumber()).collect(Collectors.joining(","));
|
||||
// String contentLog = username+"复制了“"+serialNumber+"”";
|
||||
// String enContentLog = username+" copied “"+serialNumber+"”.";
|
||||
// dummyLogEOService.updateLog(contentLog, projectId,CutEnum.CN.getValue());
|
||||
// dummyLogEOService.updateLog(enContentLog, projectId,CutEnum.EN.getValue());
|
||||
}
|
||||
}else{
|
||||
if(CutEnum.CN.getValue().equals(cut)){
|
||||
@@ -600,12 +600,12 @@ public class DummyInventoryInfoEOServiceImpl extends ServiceImpl<DummyInventoryI
|
||||
|
||||
if(StringUtils.isNotBlank(content)){
|
||||
contentLog = contentLog.substring(0, contentLog.length() - 5) + "”";
|
||||
dummyLogEOService.updateLog(contentLog, projectId,CutEnum.CN.getValue());
|
||||
// dummyLogEOService.updateLog(contentLog, projectId,CutEnum.CN.getValue());
|
||||
}
|
||||
|
||||
if(StringUtils.isNotBlank(enContent)){
|
||||
enContentLog = enContentLog.substring(0, enContentLog.length() - 5) + "”";
|
||||
dummyLogEOService.updateLog(enContentLog, projectId,CutEnum.EN.getValue());
|
||||
// dummyLogEOService.updateLog(enContentLog, projectId,CutEnum.EN.getValue());
|
||||
}
|
||||
}
|
||||
}else{
|
||||
|
||||
+8
-2
@@ -98,6 +98,12 @@ public class ConditionAssessmentEOServiceImpl extends ServiceImpl<ConditionAsses
|
||||
QueryWrapper<ConditionAssessmentEO> queryWrapper = new QueryWrapper<>();
|
||||
queryWrapper.lambda().eq(ConditionAssessmentEO::getProjectLawsInventoryId,projectLawsInventoryId);
|
||||
List<ConditionAssessmentEO> conditionAssessmentEOS = super.baseMapper.selectList(queryWrapper);
|
||||
if(CollectionUtils.isNotEmpty(conditionAssessmentEOS)){
|
||||
//根据角色编码去重。
|
||||
conditionAssessmentEOS = conditionAssessmentEOS.stream().collect(Collectors.collectingAndThen(Collectors.toCollection(() ->
|
||||
new TreeSet<>(Comparator.comparing(o -> o.getRoleCode()))),
|
||||
ArrayList::new));
|
||||
}
|
||||
return conditionAssessmentEOS;
|
||||
}
|
||||
|
||||
@@ -150,9 +156,9 @@ public class ConditionAssessmentEOServiceImpl extends ServiceImpl<ConditionAsses
|
||||
|
||||
QueryWrapper<ConditionAssessmentEO> queryWrapper = new QueryWrapper<>();
|
||||
queryWrapper.lambda().eq(ConditionAssessmentEO::getProjectLawsInventoryId,projectLawsInventoryId);
|
||||
if(StringUtils.isNotEmpty(projectTaskInventory.getProjectStatusAssess())){
|
||||
/*if(StringUtils.isNotEmpty(projectTaskInventory.getProjectStatusAssess())){
|
||||
queryWrapper.lambda().eq(ConditionAssessmentEO::getConditionAssessment,projectTaskInventory.getProjectStatusAssess());
|
||||
}
|
||||
}*/
|
||||
|
||||
if(StringUtils.equals(roleCode,ProjectRoleEnum.REGULATI_ENGINEER.getValue()) || StringUtils.equals(roleCode,ProjectRoleEnum.HOMOLOGATION_ENGINEER.getValue())){
|
||||
queryWrapper.lambda().eq(ConditionAssessmentEO::getCreateBy,currentUser.getUsername());
|
||||
|
||||
+47
-2
@@ -629,17 +629,40 @@ public class ProjectLawsInventoryEOServiceImpl extends ServiceImpl<ProjectLawsIn
|
||||
*/
|
||||
@Override
|
||||
public List<ProjectLawsInventoryEO> queryList(ProjectLawsInventoryEO projectLawsInventoryEO, HttpServletRequest req) {
|
||||
|
||||
String dutyTerritoryStr = "";
|
||||
if (StringUtils.isNotEmpty(projectLawsInventoryEO.getDutyTerritory())) {
|
||||
dutyTerritoryStr = projectLawsInventoryEO.getDutyTerritory();
|
||||
projectLawsInventoryEO.setDutyTerritory(null);
|
||||
}
|
||||
|
||||
QueryWrapper<ProjectLawsInventoryEO> projectLawsInventoryEOQueryWrapper = QueryGenerator.initQueryWrapper(projectLawsInventoryEO,req.getParameterMap());
|
||||
projectLawsInventoryEOQueryWrapper.orderByDesc("create_time","serial_number");
|
||||
String projectLibraryId = projectLawsInventoryEO.getProjectLibraryId();
|
||||
|
||||
if (StringUtils.isNotEmpty(dutyTerritoryStr)) {
|
||||
String finalDutyTerritoryStr = dutyTerritoryStr.replaceAll("\\*","");
|
||||
projectLawsInventoryEOQueryWrapper.and(query -> {
|
||||
query.lambda().like(ProjectLawsInventoryEO::getDutyTerritory, finalDutyTerritoryStr);
|
||||
if(StringUtils.contains(finalDutyTerritoryStr,",")){
|
||||
String[] dutyTerritoryArr = finalDutyTerritoryStr.split(",");
|
||||
for (String duty : dutyTerritoryArr) {
|
||||
query.or(q -> {
|
||||
q.like("duty_territory",duty);
|
||||
});
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
if(StringUtils.isEmpty(projectLibraryId)){
|
||||
throw new JeroBootException("项目库id不能为空!");
|
||||
}
|
||||
|
||||
LoginUser currentUser = (LoginUser) SecurityUtils.getSubject().getPrincipal();
|
||||
|
||||
projectLawsInventoryEOQueryWrapper.lambda().eq(ProjectLawsInventoryEO::getProjectLibraryId,projectLibraryId);
|
||||
//projectLawsInventoryEOQueryWrapper.lambda().eq(ProjectLawsInventoryEO::getProjectLibraryId,projectLibraryId);
|
||||
|
||||
//验证当前用户在该项目中是什么角色
|
||||
//int isProjectRole = checkUserRole(projectLibraryId, currentUser.getId(), "");
|
||||
@@ -2435,8 +2458,29 @@ public class ProjectLawsInventoryEOServiceImpl extends ServiceImpl<ProjectLawsIn
|
||||
LambdaQueryWrapper<ProjectLawsInventoryEO> wrapper = new LambdaQueryWrapper<>();
|
||||
wrapper.in(ProjectLawsInventoryEO::getId,Arrays.asList(ids.split(",")));
|
||||
List<ProjectLawsInventoryEO> projectLawsInventoryEOList = this.list(wrapper);
|
||||
List<ProjectTaskInventoryEO> projectTaskInventoryEOList = new ArrayList<>();
|
||||
for (ProjectLawsInventoryEO projectLawsInventoryEO : projectLawsInventoryEOList) {
|
||||
projectLawsInventoryEO.setId(UUID.randomUUID().toString().replace("-", ""));
|
||||
String projectLawsInventoryId = UUID.randomUUID().toString().replace("-", "");
|
||||
projectLawsInventoryEO.setId(projectLawsInventoryId);
|
||||
|
||||
projectLawsInventoryEO.setTaskAffirmStatus(TaskAffirmStatusEnum.NOT_STARTED.getValue());
|
||||
projectLawsInventoryEO.setInventoryAffirmStatus(InventoryAffirmStatusEnum.NOT_STARTED.getValue());
|
||||
projectLawsInventoryEO.setRegulationOwnerSubmitStatus(null);
|
||||
projectLawsInventoryEO.setHomologationEngineerSubmitStatus(null);
|
||||
projectLawsInventoryEO.setSendMsgFlag(null);
|
||||
projectLawsInventoryEO.setSendMsgCurrentFlag(null);
|
||||
projectLawsInventoryEO.setDesignDueDate(null);
|
||||
projectLawsInventoryEO.setPrehomoDueDate(null);
|
||||
projectLawsInventoryEO.setVerifyDueDate(null);
|
||||
projectLawsInventoryEO.setInventoryAffirmDueDate(null);
|
||||
projectLawsInventoryEO.setTaskAffirmDueDate(null);
|
||||
|
||||
ProjectTaskInventoryEO projectTaskInventoryEO = new ProjectTaskInventoryEO();
|
||||
String projectTaskInventoryId = UUID.randomUUID().toString().replace("-", "");
|
||||
projectTaskInventoryEO.setId(projectTaskInventoryId);
|
||||
projectTaskInventoryEO.setProjectLawsInventoryId(projectLawsInventoryId);
|
||||
projectTaskInventoryEO.setStandId(projectLawsInventoryEO.getStandId());
|
||||
projectTaskInventoryEOList.add(projectTaskInventoryEO);
|
||||
}
|
||||
this.saveBatch(projectLawsInventoryEOList);
|
||||
|
||||
@@ -2449,6 +2493,7 @@ public class ProjectLawsInventoryEOServiceImpl extends ServiceImpl<ProjectLawsIn
|
||||
String enContentLog = username+" copied “"+serialNumber+"”";
|
||||
projectLawsInventoryLogEOService.updateLog(contentLog, projectLibraryId,CutEnum.CN.getValue());
|
||||
projectLawsInventoryLogEOService.updateLog(enContentLog, projectLibraryId,CutEnum.EN.getValue());
|
||||
this.projectTaskInventoryEOService.saveBatch(projectTaskInventoryEOList);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
+23
-1
@@ -169,12 +169,34 @@ public class ProjectTaskInventoryEOServiceImpl extends ServiceImpl<ProjectTaskIn
|
||||
LoginUser currentUser = (LoginUser) SecurityUtils.getSubject().getPrincipal();
|
||||
ProjectLawsInventoryEO projectLawsInventoryEO = new ProjectLawsInventoryEO();
|
||||
projectLawsInventoryEO.setSerialNumber(projectTaskInventoryEO.getSerialNumber());
|
||||
projectLawsInventoryEO.setDutyTerritory(projectTaskInventoryEO.getDutyTerritory());
|
||||
//projectLawsInventoryEO.setDutyTerritory(projectTaskInventoryEO.getDutyTerritory());
|
||||
QueryWrapper<ProjectLawsInventoryEO> lawsInventoryEOQueryWrapper = QueryGenerator.initQueryWrapper(projectLawsInventoryEO,req.getParameterMap());
|
||||
//QueryWrapper<ProjectLawsInventoryEO> lawsInventoryEOQueryWrapper = new QueryWrapper<>();
|
||||
lawsInventoryEOQueryWrapper.lambda().eq(ProjectLawsInventoryEO::getProjectLibraryId,projectLibraryId);
|
||||
lawsInventoryEOQueryWrapper.lambda().eq(ProjectLawsInventoryEO::getInventoryAffirmStatus, InventoryAffirmStatusEnum.ACCEPTED.getValue());
|
||||
lawsInventoryEOQueryWrapper.lambda().eq(ProjectLawsInventoryEO::getTaskAffirmStatus, TaskAffirmStatusEnum.ACCEPTED.getValue());
|
||||
|
||||
String dutyTerritoryStr = "";
|
||||
if (StringUtils.isNotEmpty(projectTaskInventoryEO.getDutyTerritory())) {
|
||||
dutyTerritoryStr = projectTaskInventoryEO.getDutyTerritory();
|
||||
projectTaskInventoryEO.setDutyTerritory(null);
|
||||
}
|
||||
|
||||
if (StringUtils.isNotEmpty(dutyTerritoryStr)) {
|
||||
String finalDutyTerritoryStr = dutyTerritoryStr.replaceAll("\\*","");
|
||||
lawsInventoryEOQueryWrapper.and(query -> {
|
||||
query.lambda().like(ProjectLawsInventoryEO::getDutyTerritory, finalDutyTerritoryStr);
|
||||
if(StringUtils.contains(finalDutyTerritoryStr,",")){
|
||||
String[] dutyTerritoryArr = finalDutyTerritoryStr.split(",");
|
||||
for (String duty : dutyTerritoryArr) {
|
||||
query.or(q -> {
|
||||
q.like("duty_territory",duty);
|
||||
});
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
List<ProjectLawsInventoryEO> projectLawsInventoryEOList = projectLawsInventoryEOMapper.selectList(lawsInventoryEOQueryWrapper);
|
||||
|
||||
if(CollectionUtils.isNotEmpty(projectLawsInventoryEOList)){
|
||||
|
||||
Reference in New Issue
Block a user