diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/entity/ProjectLibraryBase.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/entity/ProjectLibraryBase.java index d831a5896..4ae6bda7f 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/entity/ProjectLibraryBase.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/entity/ProjectLibraryBase.java @@ -141,4 +141,9 @@ public class ProjectLibraryBase implements Comparable { // return o.id-this.id;//降序 } + public String getShowName(){ + return projectName+yearName+targetMarket+projectVersion; + } + + } diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/service/impl/ProjectStatusBoardServiceImpl.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/service/impl/ProjectStatusBoardServiceImpl.java index f1c2495ad..77c0e4c95 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/service/impl/ProjectStatusBoardServiceImpl.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/service/impl/ProjectStatusBoardServiceImpl.java @@ -27,14 +27,7 @@ import org.springframework.stereotype.Service; import javax.servlet.http.HttpServletRequest; import java.text.SimpleDateFormat; -import java.util.ArrayList; -import java.util.Calendar; -import java.util.Collections; -import java.util.Date; -import java.util.HashMap; -import java.util.LinkedList; -import java.util.List; -import java.util.Map; +import java.util.*; import java.util.stream.Collectors; /** @@ -128,6 +121,7 @@ public class ProjectStatusBoardServiceImpl implements IProjectStatusBoardService projectLibraryBaseLinkedList.addAll(projectLibraryBaseListTemp); } } + projectLibraryBaseList.sort(Comparator.comparing(ProjectLibraryBase::getShowName)); List dictItemList = sysDictItemServiceImpl.selectItemsByDictCode("region"); for (ProjectLibraryBase libraryBase : projectLibraryBaseList) { @@ -190,6 +184,7 @@ public class ProjectStatusBoardServiceImpl implements IProjectStatusBoardService } + projectLibraryBaseList.sort(Comparator.comparing(ProjectLibraryBase::getShowName)); for (ProjectLibraryBase libraryBase : projectLibraryBaseList) { //处理目标市场 targetMarket(projectLibraryBase, dictItemList, libraryBase); @@ -201,8 +196,12 @@ public class ProjectStatusBoardServiceImpl implements IProjectStatusBoardService if(projectTaskInventoryEOList.size() != 0){ projectTaskInventoryEOS = projectTaskInventoryEOList.stream().filter(e -> ProjectLawsInventoryIdList.contains(e.getProjectLawsInventoryId())).collect(Collectors.toList()); } + String projectVersion = libraryBase.getProjectVersion(); + if(StringUtils.isBlank(projectVersion)){ + projectVersion = "00"; + } Map map = new HashMap<>(); - map.put("projectName",libraryBase.getProjectName());//项目名称 + map.put("projectName",libraryBase.getProjectName()+" "+libraryBase.getYearName()+"-"+libraryBase.getTargetMarket()+"-"+projectVersion);//项目名称 map.put("targetMarket",libraryBase.getTargetMarket());//目标市场 //1. 项目当前状态--projectState(蓝/红/黄/绿)-->studio视角下的数据 diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/report/util/WordUtil.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/report/util/WordUtil.java index 1e6fd5ceb..1b56973eb 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/report/util/WordUtil.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/report/util/WordUtil.java @@ -575,7 +575,9 @@ public class WordUtil { String applyScopeName = dictItem(sysDictItems, applyScope,cut, DictCodeReportEnum.APPLYSCOPE.getValue()); String stateName = dictItem(sysDictItems, state,cut, DictCodeReportEnum.STATE_REPORT.getValue()); String useMethodName = dictItem(sysDictItems, useMethod,cut, DictCodeReportEnum.USEMETHOD.getValue()); - + if(useMethodName.equals("安装即符合")){ + useMethodName = "安装需符合"; + } XWPFTable table = document.createTable(10, 2); //表格属性 CTTblPr tablePr = table.getCTTbl().addNewTblPr(); @@ -1193,16 +1195,18 @@ public class WordUtil { setBlank(text, run, sb, itemText); } if("Scope".equals(fieldName)){ + // M,N,Enterprise,Vehicle,System/Parts,New Car Model,Models In Production + // M,N,Enterprise,Vehicle,System/Part ,New Type ,New Vehicle String itemText = "M,N,Enterprise,Vehicle,System/Parts,New Car Model,Models In Production"; setBlank(text, run, sb, itemText); - } if("状态".equals(fieldName)){ String itemText = "草稿,公示稿,发布稿"; setBlank(text, run, sb, itemText); } if("Status".equals(fieldName)){ - String itemText = "Draft,Public Notice,Release"; + // Draft,Public Notice,Release + String itemText = "Draft,Publicity,Final"; setBlank(text, run, sb, itemText); } if("用法".equals(fieldName)){ @@ -1222,12 +1226,39 @@ public class WordUtil { } private static void setBlank(String text, XWPFRun run, StringBuilder sb, String itemText) { + //用法的三个复选框 在后端get到的英文和导出的word对应不上,也就是和itemText中给定的内容对应不上 + if(text.equals("constraint")){ + text = "Mandatory"; + } + if(text.equals("recommend")){ + text = "Voluntary"; + } + if(text.equals("installation is compliant")){ + text = "Mandatory if fitted"; + } + + if(text.equals("Public Notice")){ + text = "Publicity"; + } + if(text.equals("Release")){ + text = "Final"; + } + + for (String value : itemText.split(",")) { String blank = getBlank(value); - if(text.contains(value)){ + //contains()方法 当选中的是Mandatory if fitted时,Mandatory也包含在其中结果会是true,也会被选中 + if(text.equals("Mandatory if fitted") && value.equals("Mandatory if fitted")){ sb.append("■"+value+blank); + break; + } + if(text.contains(value)){ + //将错误的英文转为正确的 + String value1 = scopeConvert(value); + sb.append("■"+value1+blank); }else{ - sb.append("□"+value+blank); + String value1 = scopeConvert(value); + sb.append("□"+value1+blank); } } String[] split = sb.toString().split("\r\n"); @@ -1239,6 +1270,23 @@ public class WordUtil { } } + private static String scopeConvert(String text){ + + if(text.equals("System/Parts")){ + text = "System/Part "; + return text; + } + if(text.equals("New Car Model")){ + text = "New Type "; + return text; + } + if(text.equals("Models In Production")){ + text = "New Vehicle "; + return text; + } + return text; + } + public static String getBlank(String value){ String blank = ""; switch (value) { @@ -1361,7 +1409,6 @@ public class WordUtil { // 设置链接字体大小 CTHpsMeasure sz = rpr.isSetSz() ? rpr.getSz() : rpr.addNewSz(); sz.setVal(new BigInteger("22")); - // CTHpsMeasure szCs = rpr.isSetSzCs() ? rpr.getSzCs() : rpr // .addNewSzCs(); // szCs.setVal(new BigInteger("11")); diff --git a/jero-web/src/components/tableCollection/index1.vue b/jero-web/src/components/tableCollection/index1.vue index 24c653458..c6ab13fd7 100644 --- a/jero-web/src/components/tableCollection/index1.vue +++ b/jero-web/src/components/tableCollection/index1.vue @@ -740,7 +740,7 @@ ::v-deep .ant-table-row:first-child { background: #fff !important; - opacity: 0.9; + opacity: 3; } ::v-deep .ant-table-body { diff --git a/jero-web/src/views/projectManagement/projectStatusBoard/components/projectStatusAndProgress.vue b/jero-web/src/views/projectManagement/projectStatusBoard/components/projectStatusAndProgress.vue index e24ca3362..5b7e51f9b 100644 --- a/jero-web/src/views/projectManagement/projectStatusBoard/components/projectStatusAndProgress.vue +++ b/jero-web/src/views/projectManagement/projectStatusBoard/components/projectStatusAndProgress.vue @@ -69,16 +69,16 @@ title: this.$t('entryName'), align: 'center', dataIndex: 'projectName', - width: 180, - ellipsis: true - }, - { - title: this.$t('targetMarket'), - align: 'center', - dataIndex: 'targetMarket', - width: 180, + width: 240, ellipsis: true }, + // { + // title: this.$t('targetMarket'), + // align: 'center', + // dataIndex: 'targetMarket', + // width: 180, + // ellipsis: true + // }, { align: 'center', dataIndex: 'projectStatus', diff --git a/jero-web/src/views/projectManagement/projectStatusBoard/index.vue b/jero-web/src/views/projectManagement/projectStatusBoard/index.vue index 0492867a4..096d43f20 100644 --- a/jero-web/src/views/projectManagement/projectStatusBoard/index.vue +++ b/jero-web/src/views/projectManagement/projectStatusBoard/index.vue @@ -177,16 +177,16 @@ align: 'center', dataIndex: 'projectName', scopedSlots: { customRender: 'projectName' }, - width: 180, - ellipsis: true - }, - { - title: this.$t('targetMarket'), - align: 'center', - dataIndex: 'targetMarket', - width: 180, + width: 240, ellipsis: true }, + // { + // title: this.$t('targetMarket'), + // align: 'center', + // dataIndex: 'targetMarket', + // width: 180, + // ellipsis: true + // }, { align: 'center', dataIndex: 'projectStatus',