From 75f1e249d012c1a2388b98d7f36441af4d326144 Mon Sep 17 00:00:00 2001 From: CD <1103614279@qq.com> Date: Sat, 8 Oct 2022 10:18:34 +0800 Subject: [PATCH 001/251] bug --- .../extRepo/service/impl/ExtRepoFolderServiceImpl.java | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/extRepo/service/impl/ExtRepoFolderServiceImpl.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/extRepo/service/impl/ExtRepoFolderServiceImpl.java index f9ad6ac17..5575570fa 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/extRepo/service/impl/ExtRepoFolderServiceImpl.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/extRepo/service/impl/ExtRepoFolderServiceImpl.java @@ -268,12 +268,13 @@ public class ExtRepoFolderServiceImpl extends ServiceImpl subFolderTree(String folder,List childTree,int level) { int childLevel = level + 1; List listBySupFolder = getListBySupFolder(folder); + ExtRepoFolder father = queryById(folder); for (ExtRepoFolder extRepoFolder : listBySupFolder) { ERFTreeData date = new ERFTreeData(extRepoFolder.getFolderName(), extRepoFolder.getId(), childLevel, extRepoFolder.getOrderId()); - date.setAuthManageIdsName(extRepoFolder.getAuthManageIdsName()); - date.setAuthManageIds(extRepoFolder.getAuthManageIds()); - date.setAuthViewIdsName(extRepoFolder.getAuthViewIdsName()); - date.setAuthViewIds(extRepoFolder.getAuthViewIds()); + date.setAuthManageIdsName(father.getAuthManageIdsName()); + date.setAuthManageIds(father.getAuthManageIds()); + date.setAuthViewIdsName(father.getAuthViewIdsName()); + date.setAuthViewIds(father.getAuthViewIds()); date.setChildren(subFolderTree(extRepoFolder.getId(), new ArrayList(),childLevel)); date.sortChildren(); childTree.add(date); From 0b960424d7b4b2e0b3970c69a39b08bef1d6a1eb Mon Sep 17 00:00:00 2001 From: CD <1103614279@qq.com> Date: Sat, 8 Oct 2022 10:55:01 +0800 Subject: [PATCH 002/251] bug --- .../impl/ExtRepoFolderServiceImpl.java | 19 +++++++++++++++---- 1 file changed, 15 insertions(+), 4 deletions(-) diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/extRepo/service/impl/ExtRepoFolderServiceImpl.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/extRepo/service/impl/ExtRepoFolderServiceImpl.java index 5575570fa..6c937dc85 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/extRepo/service/impl/ExtRepoFolderServiceImpl.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/extRepo/service/impl/ExtRepoFolderServiceImpl.java @@ -271,10 +271,21 @@ public class ExtRepoFolderServiceImpl extends ServiceImpl(),childLevel)); date.sortChildren(); childTree.add(date); From 747861775fb4fdf66470d16feb2a351246513129 Mon Sep 17 00:00:00 2001 From: CD <1103614279@qq.com> Date: Sat, 8 Oct 2022 14:38:54 +0800 Subject: [PATCH 003/251] bug60511 --- .../controller/ExtRepoFolderController.java | 2 +- .../jero/modules/extRepo/entity/ERFTreeData.java | 13 +++++++++++++ .../modules/extRepo/entity/ERFTreeDataVO.java | 14 +++++++------- .../service/impl/ExtRepoFolderServiceImpl.java | 15 ++++++++++++--- 4 files changed, 33 insertions(+), 11 deletions(-) diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/extRepo/controller/ExtRepoFolderController.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/extRepo/controller/ExtRepoFolderController.java index deab4288f..9e92f4c08 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/extRepo/controller/ExtRepoFolderController.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/extRepo/controller/ExtRepoFolderController.java @@ -49,7 +49,7 @@ public class ExtRepoFolderController extends JeroController queryList() { ERFTreeDataVO dataVO = new ERFTreeDataVO(); - dataVO.setManager(extRepoFolderService.isManager()); + //dataVO.setManager(extRepoFolderService.isManager()); dataVO.setList(extRepoFolderService.queryTreeList()); return Result.OK(dataVO); } diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/extRepo/entity/ERFTreeData.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/extRepo/entity/ERFTreeData.java index 0b0152705..90655a61d 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/extRepo/entity/ERFTreeData.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/extRepo/entity/ERFTreeData.java @@ -56,6 +56,19 @@ public class ERFTreeData implements Comparable { */ private String authManageIds = ""; + /** + * 是否能点击右键 + */ + private boolean rightClick; + + public boolean isRightClick() { + return rightClick; + } + + public void setRightClick(boolean rightClick) { + this.rightClick = rightClick; + } + /** * 子文件夹 */ diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/extRepo/entity/ERFTreeDataVO.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/extRepo/entity/ERFTreeDataVO.java index ba073d51e..23ca44b3b 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/extRepo/entity/ERFTreeDataVO.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/extRepo/entity/ERFTreeDataVO.java @@ -3,19 +3,19 @@ package com.jero.modules.extRepo.entity; import java.util.List; public class ERFTreeDataVO { - boolean isManager; +// boolean isManager; List list; public ERFTreeDataVO() { } - public boolean isManager() { - return isManager; - } +// public boolean isManager() { +// return isManager; +// } - public void setManager(boolean manager) { - isManager = manager; - } +// public void setManager(boolean manager) { +// isManager = manager; +// } public List getList() { return list; diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/extRepo/service/impl/ExtRepoFolderServiceImpl.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/extRepo/service/impl/ExtRepoFolderServiceImpl.java index 6c937dc85..cbdc61115 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/extRepo/service/impl/ExtRepoFolderServiceImpl.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/extRepo/service/impl/ExtRepoFolderServiceImpl.java @@ -244,11 +244,15 @@ public class ExtRepoFolderServiceImpl extends ServiceImpl(),childLevel)); + date.setChildren(subFolderTree(erf.getId(),new ArrayList(),childLevel,parentRightClick)); date.sortChildren(); resList.add(date); } else { @@ -265,12 +269,17 @@ public class ExtRepoFolderServiceImpl extends ServiceImpl subFolderTree(String folder,List childTree,int level) { + private List subFolderTree(String folder,List childTree,int level,boolean parentRightClick) { int childLevel = level + 1; List listBySupFolder = getListBySupFolder(folder); ExtRepoFolder father = queryById(folder); for (ExtRepoFolder extRepoFolder : listBySupFolder) { ERFTreeData date = new ERFTreeData(extRepoFolder.getFolderName(), extRepoFolder.getId(), childLevel, extRepoFolder.getOrderId()); + //是否有管理权限 + boolean childRightClick = haveManageAuth(extRepoFolder.getId()); + if (parentRightClick||childRightClick) { + date.setRightClick(true); + } //如果参数为空则延续父文件夹权限,反之用自己的 if (ObjectUtils.isNotEmpty(extRepoFolder.getAuthManageIds()) && ObjectUtils.isNotEmpty(extRepoFolder.getAuthManageIdsName())) { date.setAuthManageIdsName(extRepoFolder.getAuthManageIdsName()); @@ -286,7 +295,7 @@ public class ExtRepoFolderServiceImpl extends ServiceImpl(),childLevel)); + date.setChildren(subFolderTree(extRepoFolder.getId(), new ArrayList(),childLevel,childRightClick)); date.sortChildren(); childTree.add(date); } From d944ffae03e7b754e17c08b00a5ce24cd83e6dce Mon Sep 17 00:00:00 2001 From: CD <1103614279@qq.com> Date: Sat, 8 Oct 2022 14:43:21 +0800 Subject: [PATCH 004/251] =?UTF-8?q?=E6=96=87=E6=A1=A3=E5=AF=B9=E6=AF=94?= =?UTF-8?q?=E5=9B=BE=E7=89=87bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../SarFileCompareItemCommentServiceImpl.java | 149 ++++++------------ 1 file changed, 48 insertions(+), 101 deletions(-) diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/service/impl/SarFileCompareItemCommentServiceImpl.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/service/impl/SarFileCompareItemCommentServiceImpl.java index c13dd7034..ba903bf84 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/service/impl/SarFileCompareItemCommentServiceImpl.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/service/impl/SarFileCompareItemCommentServiceImpl.java @@ -278,57 +278,30 @@ public class SarFileCompareItemCommentServiceImpl extends ServiceImpl 1) { for (int j = 0; j < leftSplit.length; j++) { - if (j > 0) { - Row row2 = sheet.createRow(j + i); - if (leftSplit[j].contains(".jpg") || leftSplit[j].contains(".png")) { - row2.setHeight((short) 5000); //设置行高 - //先将图片下载到本地 - String fileLastName = leftSplit[j].substring(leftSplit[j].lastIndexOf("/") + 1); - if (CosBootUtil.doesObjectExist(leftSplit[j])) { - try (InputStream in = CosBootUtil.download(leftSplit[j])) { - copyFile2(in, dir + File.separator + fileLastName); - } catch (IOException e) { - e.printStackTrace(); - log.error(e.getMessage(), e); - } + Row row2 = sheet.createRow(j + i); + if (leftSplit[j].contains("/upFiles")) { + row2.setHeight((short) 5000); //设置行高 + //先将图片下载到本地 + String fileLastName = leftSplit[j].substring(leftSplit[j].lastIndexOf("/") + 1); + if (CosBootUtil.doesObjectExist(leftSplit[j])) { + try (InputStream in = CosBootUtil.download(leftSplit[j])) { + copyFile2(in, dir + File.separator + fileLastName); + } catch (IOException e) { + e.printStackTrace(); + log.error(e.getMessage(), e); } - File file = new File(dir + File.separator + fileLastName); - if (file.exists()) { - bufferImg = ImageIO.read(file); - ImageIO.write(bufferImg, "jpg", byteArrayOut); - //anchor主要用于设置图片的属性 - HSSFClientAnchor anchor = new HSSFClientAnchor(0, 0, 600, 200, (short) 3, j + i, (short) 3, j + i); - patriarch.createPicture(anchor, workbook.addPicture(byteArrayOut.toByteArray(), HSSFWorkbook.PICTURE_TYPE_JPEG)); + } + File file = new File(dir + File.separator + fileLastName); + if (file.exists()) { + bufferImg = ImageIO.read(file); + ImageIO.write(bufferImg, "jpg", byteArrayOut); + //anchor主要用于设置图片的属性 + HSSFClientAnchor anchor = new HSSFClientAnchor(0, 0, 600, 200, (short) 3, j + i, (short) 3, j + i); + patriarch.createPicture(anchor, workbook.addPicture(byteArrayOut.toByteArray(), HSSFWorkbook.PICTURE_TYPE_JPEG)); - } - } else { - row2.createCell(3).setCellValue(leftSplit[j]); } } else { - if (leftSplit[j].contains(".jpg") || leftSplit[j].contains(".png")) { - row.setHeight((short) 5000); //设置行高 - //先将图片下载到本地 - String fileLastName = leftSplit[j].substring(leftSplit[j].lastIndexOf("/") + 1); - if (CosBootUtil.doesObjectExist(leftSplit[j])) { - try (InputStream in = CosBootUtil.download(leftSplit[j])) { - copyFile2(in, dir + File.separator + fileLastName); - } catch (IOException e) { - e.printStackTrace(); - log.error(e.getMessage(), e); - } - } - File file = new File(dir + File.separator + fileLastName); - if (file.exists()) { - bufferImg = ImageIO.read(file); - ImageIO.write(bufferImg, "jpg", byteArrayOut); - //anchor主要用于设置图片的属性 - HSSFClientAnchor anchor = new HSSFClientAnchor(0, 0, 600, 200, (short) 3, j + i, (short) 3, j + i); - patriarch.createPicture(anchor, workbook.addPicture(byteArrayOut.toByteArray(), HSSFWorkbook.PICTURE_TYPE_JPEG)); - - } - } else { - row.createCell(3).setCellValue(leftSplit[j]); - } + row2.createCell(3).setCellValue(leftSplit[j]); } } sarFileCompareExcelMergeCell.setLeftStart(i); @@ -357,57 +330,30 @@ public class SarFileCompareItemCommentServiceImpl extends ServiceImpl 1) { for (int j = 0; j < rightSplit.length; j++) { - if (j > 0) { - Row row2 = sheet.createRow(j + i); - if (rightSplit[j].contains(".jpg") || rightSplit[j].contains(".png")) { - row2.setHeight((short) 5000); //设置行高 - //先将图片下载到本地 - String fileLastName = rightSplit[j].substring(rightSplit[j].lastIndexOf("/") + 1); - if (CosBootUtil.doesObjectExist(rightSplit[j])) { - try (InputStream in = CosBootUtil.download(rightSplit[j])) { - copyFile2(in, dir + File.separator + fileLastName); - } catch (IOException e) { - e.printStackTrace(); - log.error(e.getMessage(), e); - } + Row row2 = sheet.createRow(j + i); + if (rightSplit[j].contains("/upFiles")) { + row2.setHeight((short) 5000); //设置行高 + //先将图片下载到本地 + String fileLastName = rightSplit[j].substring(rightSplit[j].lastIndexOf("/") + 1); + if (CosBootUtil.doesObjectExist(rightSplit[j])) { + try (InputStream in = CosBootUtil.download(rightSplit[j])) { + copyFile2(in, dir + File.separator + fileLastName); + } catch (IOException e) { + e.printStackTrace(); + log.error(e.getMessage(), e); } - File file = new File(dir + File.separator + fileLastName); - if (file.exists()) { - bufferImg = ImageIO.read(file); - ImageIO.write(bufferImg, "jpg", byteArrayOut); - //anchor主要用于设置图片的属性 - HSSFClientAnchor anchor = new HSSFClientAnchor(0, 0, 600, 200, (short) 3, j + i, (short) 3, j + i); - patriarch.createPicture(anchor, workbook.addPicture(byteArrayOut.toByteArray(), HSSFWorkbook.PICTURE_TYPE_JPEG)); + } + File file = new File(dir + File.separator + fileLastName); + if (file.exists()) { + bufferImg = ImageIO.read(file); + ImageIO.write(bufferImg, "jpg", byteArrayOut); + //anchor主要用于设置图片的属性 + HSSFClientAnchor anchor = new HSSFClientAnchor(0, 0, 600, 200, (short) 7, j + i, (short) 7, j + i); + patriarch.createPicture(anchor, workbook.addPicture(byteArrayOut.toByteArray(), HSSFWorkbook.PICTURE_TYPE_JPEG)); - } - } else { - row2.createCell(3).setCellValue(rightSplit[j]); } } else { - if (rightSplit[j].contains(".jpg") || rightSplit[j].contains(".png")) { - row.setHeight((short) 5000); //设置行高 - //先将图片下载到本地 - String fileLastName = rightSplit[j].substring(rightSplit[j].lastIndexOf("/") + 1); - if (CosBootUtil.doesObjectExist(rightSplit[j])) { - try (InputStream in = CosBootUtil.download(rightSplit[j])) { - copyFile2(in, dir + File.separator + fileLastName); - } catch (IOException e) { - e.printStackTrace(); - log.error(e.getMessage(), e); - } - } - File file = new File(dir + File.separator + fileLastName); - if (file.exists()) { - bufferImg = ImageIO.read(file); - ImageIO.write(bufferImg, "jpg", byteArrayOut); - //anchor主要用于设置图片的属性 - HSSFClientAnchor anchor = new HSSFClientAnchor(0, 0, 600, 200, (short) 3, j + i, (short) 3, j + i); - patriarch.createPicture(anchor, workbook.addPicture(byteArrayOut.toByteArray(), HSSFWorkbook.PICTURE_TYPE_JPEG)); - - } - } else { - row.createCell(7).setCellValue(rightSplit[j]); - } + row2.createCell(7).setCellValue(rightSplit[j]); } } sarFileCompareExcelMergeCell.setRightStart(i); @@ -443,7 +389,8 @@ public class SarFileCompareItemCommentServiceImpl extends ServiceImpl mergeCellSet = new HashSet<>(mergeCells); + for (SarFileCompareExcelMergeCell mergeCell : mergeCellSet) { Integer leftCount = mergeCell.getLeftEnd() - mergeCell.getLeftStart() + 1; Integer rightCount = mergeCell.getRightEnd() - mergeCell.getRightStart() + 1; Integer start = leftCount - rightCount >= 0 ? mergeCell.getLeftStart() : mergeCell.getRightStart(); @@ -461,7 +408,7 @@ public class SarFileCompareItemCommentServiceImpl extends ServiceImpl")) { - String txtLeft = text.substring(0, text.indexOf("<")); - String txtRight = text.substring(text.indexOf(">") + 1); - String img = text.substring(text.indexOf("<"), text.indexOf(">")); - String path = img.substring(img.lastIndexOf("=") + 1, img.lastIndexOf("\"")); + if (text.contains("") + 3); + String img = text.substring(text.indexOf("")); + String path = img.substring(img.lastIndexOf("=") + 1)+"g"; text = txtLeft + "---" + path + "---" + txtRight; addImgdata(text, session); } else { From 222fcb8b4fbb80e1b1ba4f9f2eb1f77dbcc91614 Mon Sep 17 00:00:00 2001 From: CD <1103614279@qq.com> Date: Sat, 8 Oct 2022 15:00:53 +0800 Subject: [PATCH 005/251] =?UTF-8?q?=E5=AF=B9=E5=A4=96=E6=8A=A5=E5=91=8A?= =?UTF-8?q?=E5=8F=B3=E9=94=AE=E7=82=B9=E5=87=BB?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/jero/modules/extRepo/entity/ERFTreeData.java | 10 +++++----- .../extRepo/service/impl/ExtRepoFolderServiceImpl.java | 4 ++-- jero-web/src/views/externalReports/index.vue | 3 ++- 3 files changed, 9 insertions(+), 8 deletions(-) diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/extRepo/entity/ERFTreeData.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/extRepo/entity/ERFTreeData.java index 90655a61d..04a4af70d 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/extRepo/entity/ERFTreeData.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/extRepo/entity/ERFTreeData.java @@ -59,14 +59,14 @@ public class ERFTreeData implements Comparable { /** * 是否能点击右键 */ - private boolean rightClick; + private boolean isManager; - public boolean isRightClick() { - return rightClick; + public boolean isManager() { + return isManager; } - public void setRightClick(boolean rightClick) { - this.rightClick = rightClick; + public void setManager(boolean manager) { + isManager = manager; } /** diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/extRepo/service/impl/ExtRepoFolderServiceImpl.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/extRepo/service/impl/ExtRepoFolderServiceImpl.java index cbdc61115..6acafb9e0 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/extRepo/service/impl/ExtRepoFolderServiceImpl.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/extRepo/service/impl/ExtRepoFolderServiceImpl.java @@ -246,7 +246,7 @@ public class ExtRepoFolderServiceImpl extends ServiceImpl Date: Sat, 8 Oct 2022 15:14:16 +0800 Subject: [PATCH 006/251] =?UTF-8?q?=E6=96=87=E6=A1=A3=E5=AF=B9=E6=AF=94?= =?UTF-8?q?=E5=9B=BE=E7=89=87bug2.0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../SarFileCompareItemCommentServiceImpl.java | 138 ++++++++++++------ 1 file changed, 96 insertions(+), 42 deletions(-) diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/service/impl/SarFileCompareItemCommentServiceImpl.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/service/impl/SarFileCompareItemCommentServiceImpl.java index ba903bf84..bc0fa2836 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/service/impl/SarFileCompareItemCommentServiceImpl.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/service/impl/SarFileCompareItemCommentServiceImpl.java @@ -271,37 +271,64 @@ public class SarFileCompareItemCommentServiceImpl extends ServiceImpl", "").replace("

", "\r\n"); - BufferedImage bufferImg = null; ByteArrayOutputStream byteArrayOut = new ByteArrayOutputStream(); addImgdata(text,request.getSession()); String rowDataAndPath = (String) request.getSession().getAttribute("txtAndImg"); leftSplit = rowDataAndPath.split("---"); if (leftSplit.length > 1) { for (int j = 0; j < leftSplit.length; j++) { - Row row2 = sheet.createRow(j + i); - if (leftSplit[j].contains("/upFiles")) { - row2.setHeight((short) 5000); //设置行高 - //先将图片下载到本地 - String fileLastName = leftSplit[j].substring(leftSplit[j].lastIndexOf("/") + 1); - if (CosBootUtil.doesObjectExist(leftSplit[j])) { - try (InputStream in = CosBootUtil.download(leftSplit[j])) { - copyFile2(in, dir + File.separator + fileLastName); - } catch (IOException e) { - e.printStackTrace(); - log.error(e.getMessage(), e); + BufferedImage bufferImg = null; + if (j > 0) { + Row row2 = sheet.createRow(j + i); + if (leftSplit[j].contains("/upFiles")) { + row2.setHeight((short) 5000); //设置行高 + //先将图片下载到本地 + String fileLastName = leftSplit[j].substring(leftSplit[j].lastIndexOf("/") + 1); + if (CosBootUtil.doesObjectExist(leftSplit[j])) { + try (InputStream in = CosBootUtil.download(leftSplit[j])) { + copyFile2(in, dir + File.separator + fileLastName); + } catch (IOException e) { + e.printStackTrace(); + log.error(e.getMessage(), e); + } } - } - File file = new File(dir + File.separator + fileLastName); - if (file.exists()) { - bufferImg = ImageIO.read(file); - ImageIO.write(bufferImg, "jpg", byteArrayOut); - //anchor主要用于设置图片的属性 - HSSFClientAnchor anchor = new HSSFClientAnchor(0, 0, 600, 200, (short) 3, j + i, (short) 3, j + i); - patriarch.createPicture(anchor, workbook.addPicture(byteArrayOut.toByteArray(), HSSFWorkbook.PICTURE_TYPE_JPEG)); + File file = new File(dir + File.separator + fileLastName); + if (file.exists()) { + bufferImg = ImageIO.read(file); + ImageIO.write(bufferImg, "jpg", byteArrayOut); + //anchor主要用于设置图片的属性 + HSSFClientAnchor anchor = new HSSFClientAnchor(0, 0, 600, 200, (short) 3, j + i, (short) 3, j + i); + patriarch.createPicture(anchor, workbook.addPicture(byteArrayOut.toByteArray(), HSSFWorkbook.PICTURE_TYPE_JPEG)); + } + } else { + row2.createCell(3).setCellValue(leftSplit[j]); } } else { - row2.createCell(3).setCellValue(leftSplit[j]); + if (leftSplit[j].contains(".jpg") || leftSplit[j].contains(".png")) { + row.setHeight((short) 5000); //设置行高 + //先将图片下载到本地 + String fileLastName = leftSplit[j].substring(leftSplit[j].lastIndexOf("/") + 1); + if (CosBootUtil.doesObjectExist(leftSplit[j])) { + try (InputStream in = CosBootUtil.download(leftSplit[j])) { + copyFile2(in, dir + File.separator + fileLastName); + } catch (IOException e) { + e.printStackTrace(); + log.error(e.getMessage(), e); + } + } + File file = new File(dir + File.separator + fileLastName); + if (file.exists()) { + bufferImg = ImageIO.read(file); + ImageIO.write(bufferImg, "jpg", byteArrayOut); + //anchor主要用于设置图片的属性 + HSSFClientAnchor anchor = new HSSFClientAnchor(0, 0, 600, 200, (short) 3, j + i, (short) 3, j + i); + patriarch.createPicture(anchor, workbook.addPicture(byteArrayOut.toByteArray(), HSSFWorkbook.PICTURE_TYPE_JPEG)); + + } + } else { + row.createCell(3).setCellValue(leftSplit[j]); + } } } sarFileCompareExcelMergeCell.setLeftStart(i); @@ -323,37 +350,64 @@ public class SarFileCompareItemCommentServiceImpl extends ServiceImpl", "").replace("

", "\r\n"); - BufferedImage bufferImg = null; ByteArrayOutputStream byteArrayOut = new ByteArrayOutputStream(); addImgdata(text,request.getSession()); String rowDataAndPath = (String) request.getSession().getAttribute("txtAndImg"); rightSplit = rowDataAndPath.split("---"); if (rightSplit.length > 1) { for (int j = 0; j < rightSplit.length; j++) { - Row row2 = sheet.createRow(j + i); - if (rightSplit[j].contains("/upFiles")) { - row2.setHeight((short) 5000); //设置行高 - //先将图片下载到本地 - String fileLastName = rightSplit[j].substring(rightSplit[j].lastIndexOf("/") + 1); - if (CosBootUtil.doesObjectExist(rightSplit[j])) { - try (InputStream in = CosBootUtil.download(rightSplit[j])) { - copyFile2(in, dir + File.separator + fileLastName); - } catch (IOException e) { - e.printStackTrace(); - log.error(e.getMessage(), e); + BufferedImage bufferImg = null; + if (j > 0) { + Row row2 = sheet.createRow(j + i); + if (rightSplit[j].contains("/upFiles")) { + row2.setHeight((short) 5000); //设置行高 + //先将图片下载到本地 + String fileLastName = rightSplit[j].substring(rightSplit[j].lastIndexOf("/") + 1); + if (CosBootUtil.doesObjectExist(rightSplit[j])) { + try (InputStream in = CosBootUtil.download(rightSplit[j])) { + copyFile2(in, dir + File.separator + fileLastName); + } catch (IOException e) { + e.printStackTrace(); + log.error(e.getMessage(), e); + } } - } - File file = new File(dir + File.separator + fileLastName); - if (file.exists()) { - bufferImg = ImageIO.read(file); - ImageIO.write(bufferImg, "jpg", byteArrayOut); - //anchor主要用于设置图片的属性 - HSSFClientAnchor anchor = new HSSFClientAnchor(0, 0, 600, 200, (short) 7, j + i, (short) 7, j + i); - patriarch.createPicture(anchor, workbook.addPicture(byteArrayOut.toByteArray(), HSSFWorkbook.PICTURE_TYPE_JPEG)); + File file = new File(dir + File.separator + fileLastName); + if (file.exists()) { + bufferImg = ImageIO.read(file); + ImageIO.write(bufferImg, "jpg", byteArrayOut); + //anchor主要用于设置图片的属性 + HSSFClientAnchor anchor = new HSSFClientAnchor(0, 0, 600, 200, (short) 7, j + i, (short) 7, j + i); + patriarch.createPicture(anchor, workbook.addPicture(byteArrayOut.toByteArray(), HSSFWorkbook.PICTURE_TYPE_JPEG)); + } + } else { + row2.createCell(7).setCellValue(rightSplit[j]); } } else { - row2.createCell(7).setCellValue(rightSplit[j]); + if (rightSplit[j].contains(".jpg") || rightSplit[j].contains(".png")) { + row.setHeight((short) 5000); //设置行高 + //先将图片下载到本地 + String fileLastName = rightSplit[j].substring(rightSplit[j].lastIndexOf("/") + 1); + if (CosBootUtil.doesObjectExist(rightSplit[j])) { + try (InputStream in = CosBootUtil.download(rightSplit[j])) { + copyFile2(in, dir + File.separator + fileLastName); + } catch (IOException e) { + e.printStackTrace(); + log.error(e.getMessage(), e); + } + } + File file = new File(dir + File.separator + fileLastName); + if (file.exists()) { + bufferImg = ImageIO.read(file); + ImageIO.write(bufferImg, "jpg", byteArrayOut); + //anchor主要用于设置图片的属性 + HSSFClientAnchor anchor = new HSSFClientAnchor(0, 0, 600, 200, (short) 3, j + i, (short) 3, j + i); + patriarch.createPicture(anchor, workbook.addPicture(byteArrayOut.toByteArray(), HSSFWorkbook.PICTURE_TYPE_JPEG)); + + } + } else { + row.createCell(7).setCellValue(rightSplit[j]); + } } } sarFileCompareExcelMergeCell.setRightStart(i); From cfed5d9e614d5dd1b123db8f0097b7e25f026359 Mon Sep 17 00:00:00 2001 From: CD <1103614279@qq.com> Date: Sat, 8 Oct 2022 16:34:37 +0800 Subject: [PATCH 007/251] =?UTF-8?q?=E6=96=87=E6=A1=A3=E5=AF=B9=E6=AF=94?= =?UTF-8?q?=E5=AF=BC=E5=87=BAbug3.0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../SarFileCompareItemCommentServiceImpl.java | 184 +++++++++--------- 1 file changed, 94 insertions(+), 90 deletions(-) diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/service/impl/SarFileCompareItemCommentServiceImpl.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/service/impl/SarFileCompareItemCommentServiceImpl.java index bc0fa2836..c236f5d0b 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/service/impl/SarFileCompareItemCommentServiceImpl.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/service/impl/SarFileCompareItemCommentServiceImpl.java @@ -271,63 +271,65 @@ public class SarFileCompareItemCommentServiceImpl extends ServiceImpl", "").replace("

", "\r\n"); - ByteArrayOutputStream byteArrayOut = new ByteArrayOutputStream(); addImgdata(text,request.getSession()); String rowDataAndPath = (String) request.getSession().getAttribute("txtAndImg"); leftSplit = rowDataAndPath.split("---"); if (leftSplit.length > 1) { for (int j = 0; j < leftSplit.length; j++) { - BufferedImage bufferImg = null; - if (j > 0) { - Row row2 = sheet.createRow(j + i); - if (leftSplit[j].contains("/upFiles")) { - row2.setHeight((short) 5000); //设置行高 - //先将图片下载到本地 - String fileLastName = leftSplit[j].substring(leftSplit[j].lastIndexOf("/") + 1); - if (CosBootUtil.doesObjectExist(leftSplit[j])) { - try (InputStream in = CosBootUtil.download(leftSplit[j])) { - copyFile2(in, dir + File.separator + fileLastName); - } catch (IOException e) { - e.printStackTrace(); - log.error(e.getMessage(), e); + if (ObjectUtils.isNotEmpty(leftSplit[j])) { + ByteArrayOutputStream byteArrayOut = new ByteArrayOutputStream(); + BufferedImage bufferImg = null; + if (j > 0) { + Row row2 = sheet.createRow(j + i); + if (leftSplit[j].contains("/upFiles")) { + row2.setHeight((short) 3000); //设置行高 + //先将图片下载到本地 + String fileLastName = leftSplit[j].substring(leftSplit[j].lastIndexOf("/") + 1); + if (CosBootUtil.doesObjectExist(leftSplit[j])) { + try (InputStream in = CosBootUtil.download(leftSplit[j])) { + copyFile2(in, dir + File.separator + fileLastName); + } catch (IOException e) { + e.printStackTrace(); + log.error(e.getMessage(), e); + } } - } - File file = new File(dir + File.separator + fileLastName); - if (file.exists()) { - bufferImg = ImageIO.read(file); - ImageIO.write(bufferImg, "jpg", byteArrayOut); - //anchor主要用于设置图片的属性 - HSSFClientAnchor anchor = new HSSFClientAnchor(0, 0, 600, 200, (short) 3, j + i, (short) 3, j + i); - patriarch.createPicture(anchor, workbook.addPicture(byteArrayOut.toByteArray(), HSSFWorkbook.PICTURE_TYPE_JPEG)); + File file = new File(dir + File.separator + fileLastName); + if (file.exists()) { + bufferImg = ImageIO.read(file); + ImageIO.write(bufferImg, "jpg", byteArrayOut); + //anchor主要用于设置图片的属性 + HSSFClientAnchor anchor = new HSSFClientAnchor(0, 0, 600, 200, (short) 3, j + i, (short) 3, j + i); + patriarch.createPicture(anchor, workbook.addPicture(byteArrayOut.toByteArray(), HSSFWorkbook.PICTURE_TYPE_JPEG)); + } + } else { + row2.createCell(3).setCellValue(leftSplit[j]); } } else { - row2.createCell(3).setCellValue(leftSplit[j]); - } - } else { - if (leftSplit[j].contains(".jpg") || leftSplit[j].contains(".png")) { - row.setHeight((short) 5000); //设置行高 - //先将图片下载到本地 - String fileLastName = leftSplit[j].substring(leftSplit[j].lastIndexOf("/") + 1); - if (CosBootUtil.doesObjectExist(leftSplit[j])) { - try (InputStream in = CosBootUtil.download(leftSplit[j])) { - copyFile2(in, dir + File.separator + fileLastName); - } catch (IOException e) { - e.printStackTrace(); - log.error(e.getMessage(), e); + if (leftSplit[j].contains("/upFiles")) { + row.setHeight((short) 3000); //设置行高 + //先将图片下载到本地 + String fileLastName = leftSplit[j].substring(leftSplit[j].lastIndexOf("/") + 1); + if (CosBootUtil.doesObjectExist(leftSplit[j])) { + try (InputStream in = CosBootUtil.download(leftSplit[j])) { + copyFile2(in, dir + File.separator + fileLastName); + } catch (IOException e) { + e.printStackTrace(); + log.error(e.getMessage(), e); + } } - } - File file = new File(dir + File.separator + fileLastName); - if (file.exists()) { - bufferImg = ImageIO.read(file); - ImageIO.write(bufferImg, "jpg", byteArrayOut); - //anchor主要用于设置图片的属性 - HSSFClientAnchor anchor = new HSSFClientAnchor(0, 0, 600, 200, (short) 3, j + i, (short) 3, j + i); - patriarch.createPicture(anchor, workbook.addPicture(byteArrayOut.toByteArray(), HSSFWorkbook.PICTURE_TYPE_JPEG)); + File file = new File(dir + File.separator + fileLastName); + if (file.exists()) { + bufferImg = ImageIO.read(file); + ImageIO.write(bufferImg, "jpg", byteArrayOut); + //anchor主要用于设置图片的属性 + HSSFClientAnchor anchor = new HSSFClientAnchor(0, 0, 600, 200, (short) 3, j + i, (short) 3, j + i); + patriarch.createPicture(anchor, workbook.addPicture(byteArrayOut.toByteArray(), HSSFWorkbook.PICTURE_TYPE_JPEG)); + } + } else { + row.createCell(3).setCellValue(leftSplit[j]); } - } else { - row.createCell(3).setCellValue(leftSplit[j]); } } } @@ -350,63 +352,65 @@ public class SarFileCompareItemCommentServiceImpl extends ServiceImpl", "").replace("

", "\r\n"); - ByteArrayOutputStream byteArrayOut = new ByteArrayOutputStream(); addImgdata(text,request.getSession()); String rowDataAndPath = (String) request.getSession().getAttribute("txtAndImg"); rightSplit = rowDataAndPath.split("---"); if (rightSplit.length > 1) { for (int j = 0; j < rightSplit.length; j++) { - BufferedImage bufferImg = null; - if (j > 0) { - Row row2 = sheet.createRow(j + i); - if (rightSplit[j].contains("/upFiles")) { - row2.setHeight((short) 5000); //设置行高 - //先将图片下载到本地 - String fileLastName = rightSplit[j].substring(rightSplit[j].lastIndexOf("/") + 1); - if (CosBootUtil.doesObjectExist(rightSplit[j])) { - try (InputStream in = CosBootUtil.download(rightSplit[j])) { - copyFile2(in, dir + File.separator + fileLastName); - } catch (IOException e) { - e.printStackTrace(); - log.error(e.getMessage(), e); + if (ObjectUtils.isNotEmpty(rightSplit[j])) { + ByteArrayOutputStream byteArrayOut = new ByteArrayOutputStream(); + BufferedImage bufferImg = null; + if (j > 0) { + Row row2 = sheet.createRow(j + i); + if (rightSplit[j].contains("/upFiles")) { + row2.setHeight((short) 3000); //设置行高 + //先将图片下载到本地 + String fileLastName = rightSplit[j].substring(rightSplit[j].lastIndexOf("/") + 1); + if (CosBootUtil.doesObjectExist(rightSplit[j])) { + try (InputStream in = CosBootUtil.download(rightSplit[j])) { + copyFile2(in, dir + File.separator + fileLastName); + } catch (IOException e) { + e.printStackTrace(); + log.error(e.getMessage(), e); + } } - } - File file = new File(dir + File.separator + fileLastName); - if (file.exists()) { - bufferImg = ImageIO.read(file); - ImageIO.write(bufferImg, "jpg", byteArrayOut); - //anchor主要用于设置图片的属性 - HSSFClientAnchor anchor = new HSSFClientAnchor(0, 0, 600, 200, (short) 7, j + i, (short) 7, j + i); - patriarch.createPicture(anchor, workbook.addPicture(byteArrayOut.toByteArray(), HSSFWorkbook.PICTURE_TYPE_JPEG)); + File file = new File(dir + File.separator + fileLastName); + if (file.exists()) { + bufferImg = ImageIO.read(file); + ImageIO.write(bufferImg, "jpg", byteArrayOut); + //anchor主要用于设置图片的属性 + HSSFClientAnchor anchor = new HSSFClientAnchor(0, 0, 600, 200, (short) 7, j + i, (short) 7, j + i); + patriarch.createPicture(anchor, workbook.addPicture(byteArrayOut.toByteArray(), HSSFWorkbook.PICTURE_TYPE_JPEG)); + } + } else { + row2.createCell(7).setCellValue(rightSplit[j]); } } else { - row2.createCell(7).setCellValue(rightSplit[j]); - } - } else { - if (rightSplit[j].contains(".jpg") || rightSplit[j].contains(".png")) { - row.setHeight((short) 5000); //设置行高 - //先将图片下载到本地 - String fileLastName = rightSplit[j].substring(rightSplit[j].lastIndexOf("/") + 1); - if (CosBootUtil.doesObjectExist(rightSplit[j])) { - try (InputStream in = CosBootUtil.download(rightSplit[j])) { - copyFile2(in, dir + File.separator + fileLastName); - } catch (IOException e) { - e.printStackTrace(); - log.error(e.getMessage(), e); + if (rightSplit[j].contains("/upFiles")) { + row.setHeight((short) 3000); //设置行高 + //先将图片下载到本地 + String fileLastName = rightSplit[j].substring(rightSplit[j].lastIndexOf("/") + 1); + if (CosBootUtil.doesObjectExist(rightSplit[j])) { + try (InputStream in = CosBootUtil.download(rightSplit[j])) { + copyFile2(in, dir + File.separator + fileLastName); + } catch (IOException e) { + e.printStackTrace(); + log.error(e.getMessage(), e); + } } - } - File file = new File(dir + File.separator + fileLastName); - if (file.exists()) { - bufferImg = ImageIO.read(file); - ImageIO.write(bufferImg, "jpg", byteArrayOut); - //anchor主要用于设置图片的属性 - HSSFClientAnchor anchor = new HSSFClientAnchor(0, 0, 600, 200, (short) 3, j + i, (short) 3, j + i); - patriarch.createPicture(anchor, workbook.addPicture(byteArrayOut.toByteArray(), HSSFWorkbook.PICTURE_TYPE_JPEG)); + File file = new File(dir + File.separator + fileLastName); + if (file.exists()) { + bufferImg = ImageIO.read(file); + ImageIO.write(bufferImg, "jpg", byteArrayOut); + //anchor主要用于设置图片的属性 + HSSFClientAnchor anchor = new HSSFClientAnchor(0, 0, 600, 200, (short) 7, j + i, (short) 7, j + i); + patriarch.createPicture(anchor, workbook.addPicture(byteArrayOut.toByteArray(), HSSFWorkbook.PICTURE_TYPE_JPEG)); + } + } else { + row.createCell(7).setCellValue(rightSplit[j]); } - } else { - row.createCell(7).setCellValue(rightSplit[j]); } } } From b8301966413f390e65ce43e6a773c22895dc42f5 Mon Sep 17 00:00:00 2001 From: CD <1103614279@qq.com> Date: Sat, 8 Oct 2022 17:21:45 +0800 Subject: [PATCH 008/251] =?UTF-8?q?=E6=96=87=E6=A1=A3=E5=AF=B9=E6=AF=94?= =?UTF-8?q?=E5=88=9B=E5=BB=BArow=E6=97=B6=E8=A6=86=E7=9B=96=E7=9A=84?= =?UTF-8?q?=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../impl/SarFileCompareItemCommentServiceImpl.java | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/service/impl/SarFileCompareItemCommentServiceImpl.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/service/impl/SarFileCompareItemCommentServiceImpl.java index c236f5d0b..071f02deb 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/service/impl/SarFileCompareItemCommentServiceImpl.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/service/impl/SarFileCompareItemCommentServiceImpl.java @@ -280,7 +280,10 @@ public class SarFileCompareItemCommentServiceImpl extends ServiceImpl 0) { - Row row2 = sheet.createRow(j + i); + Row row2 = sheet.getRow(j + i); + if (ObjectUtils.isEmpty(row2)) { + row2 = sheet.createRow(j + i); + } if (leftSplit[j].contains("/upFiles")) { row2.setHeight((short) 3000); //设置行高 //先将图片下载到本地 @@ -361,7 +364,10 @@ public class SarFileCompareItemCommentServiceImpl extends ServiceImpl 0) { - Row row2 = sheet.createRow(j + i); + Row row2 = sheet.getRow(j + i); + if (ObjectUtils.isEmpty(row2)) { + row2 = sheet.createRow(j + i); + } if (rightSplit[j].contains("/upFiles")) { row2.setHeight((short) 3000); //设置行高 //先将图片下载到本地 From d5d39e40736b3b07cfba1773c7ea5b237f9a3d0b Mon Sep 17 00:00:00 2001 From: sunFlower <787203167@qq.com> Date: Sun, 9 Oct 2022 09:49:31 +0800 Subject: [PATCH 009/251] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E7=A6=85=E9=81=93?= =?UTF-8?q?=E5=B7=B2=E7=9F=A5bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/PersonnelSelection/index.vue | 608 ++++++++++-------- .../components/virtualNodeTree/mixin/node.js | 9 +- .../virtualNodeTree/model/tree-store.js | 1 - .../virtualNodeTree/tree-virtual-node.vue | 4 +- 4 files changed, 329 insertions(+), 293 deletions(-) diff --git a/jero-web/src/components/PersonnelSelection/index.vue b/jero-web/src/components/PersonnelSelection/index.vue index 43b6f4b88..3d8bc49f8 100644 --- a/jero-web/src/components/PersonnelSelection/index.vue +++ b/jero-web/src/components/PersonnelSelection/index.vue @@ -32,40 +32,39 @@ v-model="searchModel" @search="onSearch"/>
{{$t('dataLoading')}} - - - - - - - - - - - - - - - - - - - - - - - + ref="virtualNodeTreeRef" + :keeps="40" + show-checkbox + v-model="checkboxList" + class="treeWrap" + :defaultCheckedKeys="defaultCheckedKeys" + :defaultExpandAll="defaultExpandAll" + :check-strictly="false" + node-key="id" + @check="handleCheckChange" + @check-change="checkChange" + :data.sync="gData"> + + + {{ data.title }} + + + + + + + + + + + + + + + +
{{$t('cancel')}} @@ -107,109 +106,145 @@ defaultCheckedKeysName: [], content: [], dataList: [], - defaultExpandAll: false + defaultExpandAll: false, + searchData: '' } }, mounted() { }, methods: { - // handleCheckChange(val, checked, indeterminate) { - // if (checked) { - // this.userName.push(val.title) - // this.userIds.push(val.id) - // } else { - // for (let i = 0; i < this.userName.length; i++) { - // if (this.userName[i] == val.title) { - // this.userName.splice(i, 1) - // i-- - // } - // } - // for (let i = 0; i < this.userIds.length; i++) { - // if (this.userIds[i] == val.id) { - // this.userIds.splice(i, 1) - // i-- - // } - // } - // } - // }, + checkChange(val, checked, indeterminate) { + if (!checked && this.searchData) { + this.userName = this.userName.filter(res => { + return res != val.title + }) + this.userIds = this.userIds.filter(res => { + return res != val.id + }) + for (let i = 0; i < this.userIds.length; i++) { + if (this.userIds[i] == val.parentId) { + this.userIds.splice(i, 1) + this.userName.splice(i, 1) + i-- + } + } + } else if (checked && this.searchData) { + this.userName.push(val.title) + this.userIds.push(val.id) + } + }, + handleCheckChange(val, data, checked) { + if (!this.searchData) { + this.userName = [] + this.userIds = [] + if (data.checkedNodes && data.checkedNodes.length > 0) { + data.checkedNodes.forEach(res => { + this.userName.push(res.title) + this.userIds.push(res.id) + }) + } + } + }, standardClick() { this.treeVisible = false - this.departId = '' + // this.departId = '' this.searchModel = '' - this.userIds = [] - this.userName = [] - this.queryDepartUserTreeList(1) + this.searchData = '' + // this.userIds = [] + // this.userName = [] + // this.queryDepartUserTreeList(1) this.visible = true - // let gData = localStorage.getItem('gData') - // if (gData) { - // let dataList = JSON.parse(gData) - // if (!this.selectDepartment) { - // dataList.forEach(res => { - // if (res.type == 'Depart') { - // res.disabled = true - // } - // }) - // } - // this.dataList = this.toTree(dataList) - // } - // setTimeout(() => { - // if (gData) { - // this.gData = this.dataList - // this.gData = [...this.gData] - // // this.treeVisible = true - // if (this.personneQuery[this.query.db_field_name + 'Name']) { - // this.userName = this.personneQuery[this.query.db_field_name + 'Name'].split(',') - // } else if (this.personneQuery[this.query.db_field_name]) { - // this.userName = this.personneQuery[this.query.db_field_name].split(',') - // } else { - // this.userName = [] - // } - // if (this.personneQuery[this.query.db_field_name + '_id']) { - // this.userIds = this.personneQuery[this.query.db_field_name + '_id'].split(',') - // } else if (this.personneQuery[this.query.db_field_name]) { - // this.userIds = this.personneQuery[this.query.db_field_name].split(',') - // } else { - // this.userIds = [] - // } - // this.defaultCheckedKeys = this.userIds - // this.defaultCheckedKeys = [...this.defaultCheckedKeys] - // this.defaultExpandAll = false - // this.treeVisible = true - // } else { - // this.queryDepartUserTreeList(1) - // } - // }, 200) + let gData = localStorage.getItem('gData') + if (gData) { + let dataList = JSON.parse(gData) + if (!this.selectDepartment) { + dataList.forEach(res => { + if (res.type == 'Depart') { + res.disabled = true + } + }) + } + this.dataList = this.toTree(dataList) + } + setTimeout(() => { + if (gData) { + this.gData = this.dataList + this.gData = [...this.gData] + // this.treeVisible = true + if (this.personneQuery[this.query.db_field_name + 'Name']) { + this.userName = this.personneQuery[this.query.db_field_name + 'Name'].split(',') + } else if (this.personneQuery[this.query.db_field_name]) { + this.userName = this.personneQuery[this.query.db_field_name].split(',') + } else { + this.userName = [] + } + if (this.personneQuery[this.query.db_field_name + '_id']) { + this.userIds = this.personneQuery[this.query.db_field_name + '_id'].split(',') + } else if (this.personneQuery[this.query.db_field_name]) { + this.userIds = this.personneQuery[this.query.db_field_name].split(',') + } else { + this.userIds = [] + } + this.defaultCheckedKeys = this.userIds + this.defaultCheckedKeys = [...this.defaultCheckedKeys] + this.defaultExpandAll = false + this.treeVisible = true + } else { + this.queryDepartUserTreeList(1) + } + }, 200) + }, + deleteChildren(value, arr) { + let newarr = [] + arr.forEach(element => { + if (element.title.indexOf(value) > -1) { // 判断条件 + newarr.push(element) + } else { + if (element.children && element.children.length > 0) { + let redata = this.deleteChildren(value, element.children) + if (redata && redata.length > 0) { + let obj = { + ...element, + children: redata + } + newarr.push(obj) + } + } + } + }) + return newarr }, //将数据拼成树形结构 - // toTree(config) { - // // 删除 所有 children,以防止多次调用 - // config.forEach(function(item) { - // delete item.children - // }) - // // 将数据存储为 以 id 为 KEY 的 map 索引数据列 - // let map = {} - // config.forEach((item) => { - // item.label = item.name - // item.key = item.id - // - // item.title = item.name + (item.itemName ? ' ' + item.itemName : '') - // map[item.id] = item - // }) - // let val = [] - // config.forEach((item) => { - // // 以当前遍历项,的pid,去map对象中找到索引的id - // let parent = map[item.parentId] - // // 如果找到索引,那么说明此项不在顶级当中,那么需要把此项添加到,他对应的父级中 - // if (parent) { - // (parent.children || (parent.children = [])).push(item) - // } else { - // //如果没有在map中找到对应的索引ID,那么直接把 当前的item添加到 val结果集中,作为顶级 - // val.push(item) - // } - // }) - // return val - // }, + toTree(config, num) { + // 删除 所有 children,以防止多次调用 + config.forEach(function(item) { + delete item.children + }) + // 将数据存储为 以 id 为 KEY 的 map 索引数据列 + let map = {} + config.forEach((item) => { + item.label = item.name + item.key = item.id + + item.title = item.name + (item.itemName ? ' ' + item.itemName : '') + map[item.id] = item + }) + let val = [] + config.forEach((item) => { + // 以当前遍历项,的pid,去map对象中找到索引的id + let parent = map[item.parentId] + + // 如果找到索引,那么说明此项不在顶级当中,那么需要把此项添加到,他对应的父级中 + if (parent) { + (parent.children || (parent.children = [])).push(item) + } else { + //如果没有在map中找到对应的索引ID,那么直接把 当前的item添加到 val结果集中,作为顶级 + val.push(item) + } + }) + return val + }, standardDelete() { this.$emit('input', null) this.$forceUpdate() @@ -220,61 +255,61 @@ // this.selectedKey = selectedKeys // }, - onCheck(checkedKeys, info) { - this.userIds = checkedKeys.checked - this.userName = [] - if (this.userIds.length > 0) { - for (let i = 0; i < this.userIds.length; i++) { - for (let j = 0; j < this.defaultCheckedKeysName.length; j++) { - if (this.userIds[i] == this.defaultCheckedKeysName[j].id) { - this.userName.push(this.defaultCheckedKeysName[j].name) - } - } - } - } - if (info.checkedNodes && info.checkedNodes.length > 0) { - info.checkedNodes.forEach(res => { - if (res.data.props.dataRef.key) { - this.content.push({ - id: res.data.props.dataRef.key, - title: res.data.props.dataRef.title - }) - } else { - this.content.push({ - id: res.data.props.id, - title: res.data.props.title - }) - } - }) - } - if (this.content && this.content.length > 0) { - for (let i = 0; i < this.content.length; i++) { - for (let j = i + 1; j < this.content.length; j++) { - if (this.content[i].id == this.content[j].id) { - this.content.splice(j, 1) - j-- - } - } - } - this.userIds.forEach(res => { - this.content.forEach(val => { - if (res == val.id) { - this.userName.push(val.title) - } - }) - }) - } - if (this.userName.length > 0) { - for (let i = 0; i < this.userName.length; i++) { - for (let j = i + 1; j < this.userName.length; j++) { - if (this.userName[i] == this.userName[j]) { - this.userName.splice(j, 1) - j-- - } - } - } - } - }, + // onCheck(checkedKeys, info) { + // this.userIds = checkedKeys.checked + // this.userName = [] + // if (this.userIds.length > 0) { + // for (let i = 0; i < this.userIds.length; i++) { + // for (let j = 0; j < this.defaultCheckedKeysName.length; j++) { + // if (this.userIds[i] == this.defaultCheckedKeysName[j].id) { + // this.userName.push(this.defaultCheckedKeysName[j].name) + // } + // } + // } + // } + // if (info.checkedNodes && info.checkedNodes.length > 0) { + // info.checkedNodes.forEach(res => { + // if (res.data.props.dataRef.key) { + // this.content.push({ + // id: res.data.props.dataRef.key, + // title: res.data.props.dataRef.title + // }) + // } else { + // this.content.push({ + // id: res.data.props.id, + // title: res.data.props.title + // }) + // } + // }) + // } + // if (this.content && this.content.length > 0) { + // for (let i = 0; i < this.content.length; i++) { + // for (let j = i + 1; j < this.content.length; j++) { + // if (this.content[i].id == this.content[j].id) { + // this.content.splice(j, 1) + // j-- + // } + // } + // } + // this.userIds.forEach(res => { + // this.content.forEach(val => { + // if (res == val.id) { + // this.userName.push(val.title) + // } + // }) + // }) + // } + // if (this.userName.length > 0) { + // for (let i = 0; i < this.userName.length; i++) { + // for (let j = i + 1; j < this.userName.length; j++) { + // if (this.userName[i] == this.userName[j]) { + // this.userName.splice(j, 1) + // j-- + // } + // } + // } + // } + // }, handleCancel() { this.visible = false this.treeVisible = false @@ -289,12 +324,12 @@ } let userIds = JSON.parse(JSON.stringify(this.userIds)) let userName = JSON.parse(JSON.stringify(this.userName)) - // userName = userName.filter(function(item, index) { - // return userName.indexOf(item) === index // 因为indexOf 只能查找到第一个 - // }) - // userIds = userIds.filter(function(item, index) { - // return userIds.indexOf(item) === index // 因为indexOf 只能查找到第一个 - // }) + userName = userName.filter(function(item, index) { + return userName.indexOf(item) === index // 因为indexOf 只能查找到第一个 + }) + userIds = userIds.filter(function(item, index) { + return userIds.indexOf(item) === index // 因为indexOf 只能查找到第一个 + }) this.$emit('input', userName.join(',')) this.$emit('change', this.query.db_field_name, userIds.join(','), this.query.subscript) this.visible = false @@ -312,116 +347,119 @@ this.defaultCheckedKeys = [] }, onSearch(e) { - // this.loading = true - // this.treeVisible = false - // let p = new Promise((resolve, reject) => { - // resolve() - // }) - // p.then(() => { - // let gData = localStorage.getItem('gData') - // let content = [] - // if (gData) { - // if (e) { - // JSON.parse(gData).forEach(res => { - // if (res.type == 'User') { - // if (res.name.includes(e)) { - // res.color = true - // content.push(res) - // } - // } else if (res.type == 'Depart') { - // if (!this.selectDepartment) { - // res.disabled = true - // } - // content.push(res) - // } - // }) - // this.defaultExpandAll = true - // this.gData = this.toTree(content) - // } else { - // let content = JSON.parse(gData) - // if (!this.selectDepartment) { - // content.forEach(res => { - // if (res.type == 'Depart') { - // res.disabled = true - // } - // }) - // } - // this.gData = this.toTree(content) - // this.defaultExpandAll = false - // } - // } - // this.defaultCheckedKeys = this.userIds - // this.defaultCheckedKeys = [...this.defaultCheckedKeys] - // this.treeVisible = true - // this.loading = false - // }) - this.gData = [] - this.departId = '' - this.visibleTree = false - if (e) { - this.getUserAndDepart() - } else { - this.treeVisible = false - this.queryDepartUserTreeList(2) - } - }, - getUserAndDepart() { - getAction('sys/user/getUserAndDepart', { name: this.searchModel }).then((res) => { - if (res) { - this.gData = res.filter(ele => ele.flag === 'DEPART') - } else { - this.gData = [] - } - this.visibleTree = true + this.treeVisible = false + let p = new Promise((resolve, reject) => { + resolve() }) - }, - onExpand(selectedKeys, val) { - if (this.searchModel == '' || !this.searchModel) { - if (val.expanded) { - if (this.departId == val.node.value) { + p.then(() => { + this.searchData = e + let gData = localStorage.getItem('gData') + let content = [] + if (gData) { + if (e) { + JSON.parse(gData).forEach(res => { + if (res.type == 'User') { + if (res.name.includes(e)) { + res.color = true + content.push(res) + } + } + // else if(res.type == 'Depart'){ + // content.push(res) + // } + }) + let gDataAdmin = this.toTree(content) + this.gData = this.deleteChildren(e, gDataAdmin) + this.defaultExpandAll = true + this.treeVisible = true + this.defaultCheckedKeys = this.userIds + this.defaultCheckedKeys = [...this.defaultCheckedKeys] + this.loading = false } else { - this.departId = val.node.value - this.queryDepartUserTreeList(2) + let content = JSON.parse(gData) + if (!this.selectDepartment) { + content.forEach(res => { + if (res.type == 'Depart') { + res.disabled = true + } + }) + } + this.gData = this.toTree(content) + this.defaultExpandAll = false + this.defaultCheckedKeys = this.userIds + this.defaultCheckedKeys = [...this.defaultCheckedKeys] + this.treeVisible = true + this.loading = false } } - } + }) + // this.gData = [] + // this.departId = '' + // this.visibleTree = false + // if (e) { + // this.getUserAndDepart() + // } else { + // this.treeVisible = false + // this.queryDepartUserTreeList(2) + // } }, + // getUserAndDepart() { + // getAction('sys/user/getUserAndDepart', { name: this.searchModel }).then((res) => { + // if (res) { + // this.gData = res.filter(ele => ele.flag === 'DEPART') + // } else { + // this.gData = [] + // } + // this.visibleTree = true + // }) + // }, + // onExpand(selectedKeys, val) { + // if (this.searchModel == '' || !this.searchModel) { + // if (val.expanded) { + // if (this.departId == val.node.value) { + // } else { + // this.departId = val.node.value + // this.queryDepartUserTreeList(2) + // } + // } + // } + // }, queryDepartUserTreeList(num) { - let gData = JSON.parse(JSON.stringify(this.gData)) - if (gData && gData.length > 0) { - gData = JSON.stringify(gData) - } else { - gData = '' - } + // let gData = JSON.parse(JSON.stringify(this.gData)) + // if (gData && gData.length > 0) { + // gData = JSON.stringify(gData) + // } else { + // gData = '' + // } this.confirmLoading = true this.loading = true //queryDepartUserTreeList //queryUserTreeList - postAction('sys/user/queryDepartUserTreeList', { - departId: this.departId, - json: gData, - flag: '1' + postAction('sys/user/queryUserTreeList', { + // departId: this.departId, + // json: gData, + // flag: '1' }).then((res) => { this.confirmLoading = false if (res.success) { this.loading = false // localStorage.setItem('gData', JSON.stringify(res.result)) // this.toTree(dataList) - // let content = JSON.parse(JSON.stringify(res.result)) - // if (!this.selectDepartment) { - // res.result.forEach(res => { - // if (res.type == 'Depart') { - // res.disabled = true - // } - // }) - // } - // localStorage.removeItem('gData') - // localStorage.setItem('gData', JSON.stringify(content)) - // this.gData = this.toTree(res.result) - this.gData = res.result + let content = JSON.parse(JSON.stringify(res.result)) + if (!this.selectDepartment) { + res.result.forEach(res => { + if (res.type == 'Depart') { + res.disabled = true + } + }) + } + localStorage.removeItem('gData') + localStorage.setItem('gData', JSON.stringify(content)) + this.gData = this.toTree(res.result) + // this.gData = res.result this.gData = [...this.gData] // this.gData[0].isLeaf = false - this.defaultExpandedKeys = [this.departId] + // this.defaultExpandedKeys = [this.departId] if (num == 1) { if (this.userName && this.userName.length == 0) { if (this.personneQuery[this.query.db_field_name + 'Name']) { @@ -444,14 +482,14 @@ this.defaultCheckedKeys = this.userIds this.defaultCheckedKeys = [...this.defaultCheckedKeys] this.defaultCheckedKeysName = [] - if (this.defaultCheckedKeys.length > 0) { - for (let i = 0; i < this.defaultCheckedKeys.length; i++) { - this.defaultCheckedKeysName.push({ - id: this.defaultCheckedKeys[i], - name: this.userName[i] - }) - } - } + // if (this.defaultCheckedKeys.length > 0) { + // for (let i = 0; i < this.defaultCheckedKeys.length; i++) { + // this.defaultCheckedKeysName.push({ + // id: this.defaultCheckedKeys[i], + // name: this.userName[i] + // }) + // } + // } } this.defaultExpandAll = false this.treeVisible = true diff --git a/jero-web/src/components/virtualNodeTree/mixin/node.js b/jero-web/src/components/virtualNodeTree/mixin/node.js index 9c7850718..efeea4ce4 100644 --- a/jero-web/src/components/virtualNodeTree/mixin/node.js +++ b/jero-web/src/components/virtualNodeTree/mixin/node.js @@ -41,9 +41,8 @@ export default { return getNodeKey(this.tree.nodeKey, node.data); }, - handleSelectChange(checked, indeterminate) { + handleSelectChange(checked, indeterminate,source) { const node = this.node || this.source; - if (this.oldChecked !== checked && this.oldIndeterminate !== indeterminate) { this.tree.$emit('check-change', node.data, checked, indeterminate); } @@ -95,7 +94,6 @@ export default { handleCheckChange(_, ev) { const node = this.node || this.source; - node.setChecked(ev.target.checked, !this.tree.checkStrictly); this.$nextTick(() => { const store = this.tree.store; @@ -103,8 +101,9 @@ export default { checkedNodes: store.getCheckedNodes(), checkedKeys: store.getCheckedKeys(), halfCheckedNodes: store.getHalfCheckedNodes(), - halfCheckedKeys: store.getHalfCheckedKeys() - }); + halfCheckedKeys: store.getHalfCheckedKeys(), + getCurrentNode:store.getCurrentNode() + },this.source.checked); }); }, diff --git a/jero-web/src/components/virtualNodeTree/model/tree-store.js b/jero-web/src/components/virtualNodeTree/model/tree-store.js index c9df39c83..760ea8980 100644 --- a/jero-web/src/components/virtualNodeTree/model/tree-store.js +++ b/jero-web/src/components/virtualNodeTree/model/tree-store.js @@ -57,7 +57,6 @@ export default class TreeStore { if (node.visible && !node.isLeaf && !lazy) node.expand(); }; - traverse(this); } diff --git a/jero-web/src/components/virtualNodeTree/tree-virtual-node.vue b/jero-web/src/components/virtualNodeTree/tree-virtual-node.vue index acc2ba88e..2f0925b40 100644 --- a/jero-web/src/components/virtualNodeTree/tree-virtual-node.vue +++ b/jero-web/src/components/virtualNodeTree/tree-virtual-node.vue @@ -115,11 +115,11 @@ }, watch: { 'source.indeterminate'(val) { - this.handleSelectChange(this.source.checked, val); + this.handleSelectChange(this.source.checked, val,this.source); }, 'source.checked'(val) { - this.handleSelectChange(val, this.source.indeterminate); + this.handleSelectChange(val, this.source.indeterminate,this.source); }, 'source.expanded'(val) { From 8f63c5a27b4b99ec8520441520f35f338f470d4e Mon Sep 17 00:00:00 2001 From: sunFlower <787203167@qq.com> Date: Sun, 9 Oct 2022 14:07:22 +0800 Subject: [PATCH 010/251] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E7=A6=85=E9=81=93?= =?UTF-8?q?=E5=B7=B2=E7=9F=A5bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/evaluationResultsList.vue | 2 +- .../collectionOfRegulatoryOpinions/index.vue | 7 +++ .../components/feedbackInformation.vue | 45 ++++++++++--------- 3 files changed, 32 insertions(+), 22 deletions(-) diff --git a/jero-web/src/views/businessSupport/collectionOfRegulatoryOpinions/components/evaluationResultsList.vue b/jero-web/src/views/businessSupport/collectionOfRegulatoryOpinions/components/evaluationResultsList.vue index 1e8d605e3..85e38ad5a 100644 --- a/jero-web/src/views/businessSupport/collectionOfRegulatoryOpinions/components/evaluationResultsList.vue +++ b/jero-web/src/views/businessSupport/collectionOfRegulatoryOpinions/components/evaluationResultsList.vue @@ -209,7 +209,7 @@ actiProcInstId: this.actiProcInstId } downloadFile('/lawsOpinionGather/lawsOpinionAssessmentResultEO/exportXls', - this.$t('evaluationResults') + '.zip', query) + this.$route.query.serialNumber+ ' ' +this.$t('evaluationResults') + '.zip', query) }, getData() { this.formInline = JSON.parse(JSON.stringify(this.$route.query)) diff --git a/jero-web/src/views/businessSupport/collectionOfRegulatoryOpinions/index.vue b/jero-web/src/views/businessSupport/collectionOfRegulatoryOpinions/index.vue index 42f004c5b..5ea7211b3 100644 --- a/jero-web/src/views/businessSupport/collectionOfRegulatoryOpinions/index.vue +++ b/jero-web/src/views/businessSupport/collectionOfRegulatoryOpinions/index.vue @@ -193,6 +193,13 @@ ellipsis: true, dataIndex: 'gatherResultShow' }, + { + title: this.$t('Sponsor'), + align: 'center', + width: 140, + ellipsis: true, + dataIndex: 'createBy' + }, { title: this.$t('dateOfInitiation'), align: 'center', diff --git a/jero-web/src/views/processCenter/components/feedbackInformation.vue b/jero-web/src/views/processCenter/components/feedbackInformation.vue index 3b9722099..c86a652cb 100644 --- a/jero-web/src/views/processCenter/components/feedbackInformation.vue +++ b/jero-web/src/views/processCenter/components/feedbackInformation.vue @@ -31,25 +31,29 @@ :rules="[{ required: true, message: $t('relevantSections') + $t('cannotEmpty'), trigger: 'blur'}, {max: 300,message: $t('relevantSections') + $t('cannotExceed') + 300 + $t('Characters'),trigger: 'blur' }]"> - + + + + +
- {{$t('enclosure')}} + {{$t('clauseContent')}}
- - - {{ (item.accessoryFile === 'null' || item.accessoryFile === '' || - item.accessoryFile == null) ? $t('clickUpload') : $t('viewUploadedFiles') - }} - + +
@@ -95,16 +99,15 @@
- {{$t('clauseContent')}} + {{$t('enclosure')}}
- - + + + {{ (item.accessoryFile === 'null' || item.accessoryFile === '' || + item.accessoryFile == null) ? $t('clickUpload') : $t('viewUploadedFiles') + }} +
From d44f64535aecde7b731ecf1af2ffacff90882292 Mon Sep 17 00:00:00 2001 From: CD <1103614279@qq.com> Date: Sun, 9 Oct 2022 14:17:10 +0800 Subject: [PATCH 011/251] =?UTF-8?q?=E6=96=87=E6=A1=A3=E5=AF=B9=E6=AF=94=20?= =?UTF-8?q?=E8=A1=A8=E6=A0=BC=E6=8B=86=E5=88=86=E5=87=BA=E6=9D=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../SarFileCompareItemCommentServiceImpl.java | 236 ++++++++++-------- .../compare/utils/ConvertHtml2Excel.java | 231 +++++++++++++++++ .../compare/utils/CrossRangeCellMeta.java | 37 +++ 3 files changed, 399 insertions(+), 105 deletions(-) create mode 100644 jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/utils/ConvertHtml2Excel.java create mode 100644 jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/utils/CrossRangeCellMeta.java diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/service/impl/SarFileCompareItemCommentServiceImpl.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/service/impl/SarFileCompareItemCommentServiceImpl.java index 071f02deb..0d7fbcd94 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/service/impl/SarFileCompareItemCommentServiceImpl.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/service/impl/SarFileCompareItemCommentServiceImpl.java @@ -11,11 +11,12 @@ import com.jero.modules.compare.mapper.SarFileCompareItemCommentMapper; import com.jero.modules.compare.service.ISarFileCompareInfoService; import com.jero.modules.compare.service.ISarFileCompareItemCommentService; import com.jero.modules.compare.service.ISarFileCompareItemService; +import com.jero.modules.compare.utils.ConvertHtml2Excel; import com.jero.modules.system.util.StringUtils; import org.apache.commons.lang3.ObjectUtils; -import org.apache.poi.hssf.usermodel.HSSFClientAnchor; -import org.apache.poi.hssf.usermodel.HSSFPatriarch; -import org.apache.poi.hssf.usermodel.HSSFWorkbook; +import org.apache.poi.common.usermodel.HyperlinkType; +import org.apache.poi.hssf.usermodel.*; +import org.apache.poi.hssf.util.HSSFColor; import org.apache.poi.ss.usermodel.*; import org.apache.poi.ss.util.CellRangeAddress; import org.apache.poi.xssf.usermodel.XSSFWorkbook; @@ -253,6 +254,12 @@ public class SarFileCompareItemCommentServiceImpl extends ServiceImpl mergeCells = new ArrayList<>(); @@ -270,9 +277,7 @@ public class SarFileCompareItemCommentServiceImpl extends ServiceImpl", "").replace("

", "\r\n"); - addImgdata(text,request.getSession()); - String rowDataAndPath = (String) request.getSession().getAttribute("txtAndImg"); + String rowDataAndPath = getSplitContent(request, text); leftSplit = rowDataAndPath.split("---"); if (leftSplit.length > 1) { for (int j = 0; j < leftSplit.length; j++) { @@ -284,55 +289,9 @@ public class SarFileCompareItemCommentServiceImpl extends ServiceImpl", "").replace("

", "\r\n"); - addImgdata(text,request.getSession()); - String rowDataAndPath = (String) request.getSession().getAttribute("txtAndImg"); + String rowDataAndPath = getSplitContent(request, text); rightSplit = rowDataAndPath.split("---"); if (rightSplit.length > 1) { for (int j = 0; j < rightSplit.length; j++) { @@ -368,55 +325,9 @@ public class SarFileCompareItemCommentServiceImpl extends ServiceImpl") < 0) { + if (tableHtml.indexOf("") < 0) { + tableHtml = tableHtml.replaceFirst("", ""); + tableHtml = tableHtml.replaceFirst("", ""); + } else { + tableHtml = tableHtml.replaceFirst("", ""); + tableHtml = tableHtml.replaceFirst("", ""); + } + } + String cnt = "\n"; + tableHtml = tableHtml.replaceAll("<[\\s]*?br[^>]*?>|<[\\s]*?\\/[\\s]*?br[\\s]*?>", cnt); + String tableSheetName = "表格" + System.currentTimeMillis(); + ConvertHtml2Excel.table2Excel(tableHtml, (HSSFWorkbook) workbook, tableSheetName); + //添加超链接 + CreationHelper createHelper = workbook.getCreationHelper(); + Hyperlink hyperlink1 = createHelper.createHyperlink(HyperlinkType.DOCUMENT); + String tableName = "#\'" + tableSheetName + "\'!A1"; + hyperlink1.setAddress(tableName); + cell.setHyperlink(hyperlink1);// 链接 + cell.setCellStyle(cellStyleLink); + } + + /** + * 获取文字、图片、表格分割后的内容 + * @param request + * @param text + * @return + */ + private String getSplitContent(HttpServletRequest request, String text) { + text = text.replace("

", "").replace("

", "\r\n"); + //分割图片 + addImgdata(text, request.getSession()); + //分割表格 + String txtAndImg = (String) request.getSession().getAttribute("txtAndImg"); + txtAndImg = txtAndImg.replaceAll("table", "replaceTable"); + splitTable(txtAndImg, request.getSession()); + return (String) request.getSession().getAttribute("textAndTableAndImg"); + } + + /** + * 分割表格 + * @param textAndImg + * @param session + */ + private void splitTable(String textAndImg,HttpSession session) { + if (textAndImg.contains("") + 14); + String table = textAndImg.substring(textAndImg.indexOf("")+14); + table = table.replaceAll("replaceTable", "table"); + textAndImg = left + "---" + table + "---" + right; + splitTable(textAndImg, session); + } else { + session.setAttribute("textAndTableAndImg", textAndImg); + } + } + /** * 提取字符串中标签内容中的图片路径,并重新按顺序拼接 * @param text diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/utils/ConvertHtml2Excel.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/utils/ConvertHtml2Excel.java new file mode 100644 index 000000000..db29bbb5c --- /dev/null +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/utils/ConvertHtml2Excel.java @@ -0,0 +1,231 @@ +package com.jero.modules.compare.utils; +import java.util.ArrayList; +import java.util.List; + +import org.apache.commons.lang3.StringUtils; +import org.apache.commons.lang3.math.NumberUtils; +import org.apache.poi.hssf.usermodel.HSSFCell; +import org.apache.poi.hssf.usermodel.HSSFCellStyle; +import org.apache.poi.hssf.usermodel.HSSFFont; +import org.apache.poi.hssf.usermodel.HSSFRow; +import org.apache.poi.hssf.usermodel.HSSFSheet; +import org.apache.poi.hssf.usermodel.HSSFWorkbook; +import org.apache.poi.hssf.util.HSSFCellUtil; +import org.apache.poi.hssf.util.HSSFColor; +import org.apache.poi.ss.util.CellRangeAddress; +import org.dom4j.Document; +import org.dom4j.DocumentException; +import org.dom4j.DocumentHelper; +import org.dom4j.Element; + + +/**** + * html转excel + * @author user + * + */ +public class ConvertHtml2Excel { + /** + * html表格转excel + * + * @param tableHtml 如 + * + * .. + *
+ * @return + */ + public static void table2Excel(String tableHtml, HSSFWorkbook wb,String tableSheetName) { + HSSFSheet sheet = wb.createSheet(tableSheetName); + List crossRowEleMetaLs = new ArrayList(); + int rowIndex = 0; + try { + Document data = DocumentHelper.parseText(tableHtml); + // 生成表头 + Element thead = data.getRootElement().element("thead"); + HSSFCellStyle titleStyle = getTitleStyle(wb); + int ls=0;//列数 + if (thead != null) { + List trLs = thead.elements("tr"); + for (Element trEle : trLs) { + HSSFRow row = sheet.createRow(rowIndex); + List thLs = trEle.elements("th"); + ls=thLs.size(); + makeRowCell(thLs, rowIndex, row, 0, titleStyle, crossRowEleMetaLs); + rowIndex++; + } + } + // 生成表体 + Element tbody = data.getRootElement().element("tbody"); + HSSFCellStyle contentStyle = getContentStyle(wb); + if (tbody != null) { + List trLs = tbody.elements("tr"); + for (Element trEle : trLs) { + HSSFRow row = sheet.createRow(rowIndex); + List thLs = trEle.elements("th"); + int cellIndex = makeRowCell(thLs, rowIndex, row, 0, titleStyle, crossRowEleMetaLs); + List tdLs = trEle.elements("td"); + makeRowCell(tdLs, rowIndex, row, cellIndex, contentStyle, crossRowEleMetaLs); + rowIndex++; + } + } + // 合并表头 + for (CrossRangeCellMeta crcm : crossRowEleMetaLs) { + sheet.addMergedRegion(new CellRangeAddress(crcm.getFirstRow(), crcm.getLastRow(), crcm.getFirstCol(), crcm.getLastCol())); + setRegionStyle(sheet, new CellRangeAddress(crcm.getFirstRow(), crcm.getLastRow(), crcm.getFirstCol(), crcm.getLastCol()),contentStyle); + } + for(int i=0;i tdLs, int rowIndex, HSSFRow row, int startCellIndex, HSSFCellStyle cellStyle, + List crossRowEleMetaLs) { + int i = startCellIndex; + for (int eleIndex = 0; eleIndex < tdLs.size(); i++, eleIndex++) { + int captureCellSize = getCaptureCellSize(rowIndex, i, crossRowEleMetaLs); + while (captureCellSize > 0) { + for (int j = 0; j < captureCellSize; j++) {// 当前行跨列处理(补单元格) + row.createCell(i); + i++; + } + captureCellSize = getCaptureCellSize(rowIndex, i, crossRowEleMetaLs); + } + Element thEle = tdLs.get(eleIndex); + String val = thEle.getTextTrim(); + if (StringUtils.isBlank(val)) { + Element e = thEle.element("a"); + if (e != null) { + val = e.getTextTrim(); + } + } + HSSFCell c = row.createCell(i); + if (NumberUtils.isNumber(val)) { + c.setCellValue(Double.parseDouble(val)); + c.setCellType(HSSFCell.CELL_TYPE_NUMERIC); + } else { + c.setCellValue(val); + } + int rowSpan = NumberUtils.toInt(thEle.attributeValue("rowspan"), 1); + int colSpan = NumberUtils.toInt(thEle.attributeValue("colspan"), 1); + c.setCellStyle(cellStyle); + if (rowSpan > 1 || colSpan > 1) { // 存在跨行或跨列 + crossRowEleMetaLs.add(new CrossRangeCellMeta(rowIndex, i, rowSpan, colSpan)); + } + if (colSpan > 1) {// 当前行跨列处理(补单元格) + for (int j = 1; j < colSpan; j++) { + i++; + row.createCell(i); + } + } + } + return i; + } + + /** + * 设置合并单元格的边框样式 + * + * @param sheet + * @param region + * @param cs + */ + public static void setRegionStyle(HSSFSheet sheet, CellRangeAddress region, HSSFCellStyle cs) { + for (int i = region.getFirstRow(); i <= region.getLastRow(); i++) { + HSSFRow row = HSSFCellUtil.getRow(i, sheet); + for (int j = region.getFirstColumn(); j <= region.getLastColumn(); j++) { + HSSFCell cell = HSSFCellUtil.getCell(row, (short) j); + cell.setCellStyle(cs); + } + } + } + + /** + * 获得因rowSpan占据的单元格 + * + * @param rowIndex 行号 + * @param colIndex 列号 + * @param crossRowEleMetaLs 跨行列元数据 + * @return 当前行在某列需要占据单元格 + */ + private static int getCaptureCellSize(int rowIndex, int colIndex, List crossRowEleMetaLs) { + int captureCellSize = 0; + for (CrossRangeCellMeta crossRangeCellMeta : crossRowEleMetaLs) { + if (crossRangeCellMeta.getFirstRow() < rowIndex && crossRangeCellMeta.getLastRow() >= rowIndex) { + if (crossRangeCellMeta.getFirstCol() <= colIndex && crossRangeCellMeta.getLastCol() >= colIndex) { + captureCellSize = crossRangeCellMeta.getLastCol() - colIndex + 1; + } + } + } + return captureCellSize; + } + + /** + * 获得标题样式 + * + * @param workbook + * @return + */ + private static HSSFCellStyle getTitleStyle(HSSFWorkbook workbook) { + short titlebackgroundcolor = HSSFColor.GREY_25_PERCENT.index; + short fontSize = 12; + String fontName = "宋体"; + HSSFCellStyle style = workbook.createCellStyle(); + style.setVerticalAlignment(HSSFCellStyle.VERTICAL_CENTER); + style.setAlignment(HSSFCellStyle.ALIGN_CENTER); + style.setBorderBottom(HSSFCellStyle.BORDER_THIN); //下边框 + style.setBorderLeft(HSSFCellStyle.BORDER_THIN);//左边框 + style.setBorderTop(HSSFCellStyle.BORDER_THIN);//上边框 + style.setBorderRight(HSSFCellStyle.BORDER_THIN);//右边框 + style.setFillPattern(HSSFCellStyle.SOLID_FOREGROUND); + style.setFillForegroundColor(titlebackgroundcolor);// 背景色 + + HSSFFont font = workbook.createFont(); + font.setFontName(fontName); + font.setFontHeightInPoints(fontSize); + font.setBoldweight(HSSFFont.BOLDWEIGHT_BOLD); + style.setFont(font); + return style; + } + + /** + * 获得内容样式 + * + * @param wb + * @return + */ + private static HSSFCellStyle getContentStyle(HSSFWorkbook wb) { + short fontSize = 12; + String fontName = "宋体"; + HSSFCellStyle style = wb.createCellStyle(); + style.setBorderBottom((short) 1); + style.setBorderTop((short) 1); + style.setBorderLeft((short) 1); + style.setBorderRight((short) 1); + HSSFFont font = wb.createFont(); + font.setFontName(fontName); + font.setFontHeightInPoints(fontSize); + style.setFont(font); + style.setAlignment(HSSFCellStyle.ALIGN_CENTER);//水平居中 + style.setVerticalAlignment(HSSFCellStyle.VERTICAL_CENTER);//垂直居中 + + return style; + } +} + diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/utils/CrossRangeCellMeta.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/utils/CrossRangeCellMeta.java new file mode 100644 index 000000000..acee632aa --- /dev/null +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/utils/CrossRangeCellMeta.java @@ -0,0 +1,37 @@ +package com.jero.modules.compare.utils; + +public class CrossRangeCellMeta { + + public CrossRangeCellMeta(int firstRowIndex, int firstColIndex, int rowSpan, int colSpan) { + super(); + this.firstRowIndex = firstRowIndex; + this.firstColIndex = firstColIndex; + this.rowSpan = rowSpan; + this.colSpan = colSpan; + } + + private int firstRowIndex; + private int firstColIndex; + private int rowSpan;// 跨越行数 + private int colSpan;// 跨越列数 + + public int getFirstRow() { + return firstRowIndex; + } + + public int getLastRow() { + return firstRowIndex + rowSpan - 1; + } + + public int getFirstCol() { + return firstColIndex; + } + + public int getLastCol() { + return firstColIndex + colSpan - 1; + } + + public int getColSpan(){ + return colSpan; + } +} From af78fd1c2f4dc258a0d5bbd800662f9fa41d9e9e Mon Sep 17 00:00:00 2001 From: zhn <947514737@qq.com> Date: Sun, 9 Oct 2022 14:33:50 +0800 Subject: [PATCH 012/251] =?UTF-8?q?=E6=95=B4=E5=90=88=E5=AF=BC=E5=87=BA--?= =?UTF-8?q?=E9=A1=B5=E7=9C=89=E9=A1=B5=E8=84=9A?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../impl/LawsMonthlyReportWriteEOServiceImpl.java | 8 ++++---- .../com/jero/modules/report/util/WordUtil.java | 15 +++++++++++---- 2 files changed, 15 insertions(+), 8 deletions(-) diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/report/service/impl/LawsMonthlyReportWriteEOServiceImpl.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/report/service/impl/LawsMonthlyReportWriteEOServiceImpl.java index c309c19a3..a34563275 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/report/service/impl/LawsMonthlyReportWriteEOServiceImpl.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/report/service/impl/LawsMonthlyReportWriteEOServiceImpl.java @@ -884,8 +884,8 @@ public class LawsMonthlyReportWriteEOServiceImpl extends ServiceImpl Date: Sun, 9 Oct 2022 14:40:39 +0800 Subject: [PATCH 013/251] =?UTF-8?q?=E6=96=87=E6=A1=A3=E5=AF=B9=E6=AF=94=20?= =?UTF-8?q?=E5=8F=B3=E4=BE=A7=E5=8D=95=E5=85=83=E6=A0=BC=E6=A0=BC=E5=BC=8F?= =?UTF-8?q?bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../service/impl/SarFileCompareItemCommentServiceImpl.java | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/service/impl/SarFileCompareItemCommentServiceImpl.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/service/impl/SarFileCompareItemCommentServiceImpl.java index 0d7fbcd94..fd7d7c30f 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/service/impl/SarFileCompareItemCommentServiceImpl.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/service/impl/SarFileCompareItemCommentServiceImpl.java @@ -303,7 +303,6 @@ public class SarFileCompareItemCommentServiceImpl extends ServiceImpl Date: Sun, 9 Oct 2022 15:18:21 +0800 Subject: [PATCH 014/251] =?UTF-8?q?=E6=96=87=E6=A1=A3=E5=AF=B9=E6=AF=94=20?= =?UTF-8?q?=E4=BB=A3=E7=A0=81=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../SarFileCompareItemCommentServiceImpl.java | 38 +++++++++---------- 1 file changed, 17 insertions(+), 21 deletions(-) diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/service/impl/SarFileCompareItemCommentServiceImpl.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/service/impl/SarFileCompareItemCommentServiceImpl.java index fd7d7c30f..a635115b7 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/service/impl/SarFileCompareItemCommentServiceImpl.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/service/impl/SarFileCompareItemCommentServiceImpl.java @@ -283,7 +283,6 @@ public class SarFileCompareItemCommentServiceImpl extends ServiceImpl 0) { Row row2 = sheet.getRow(j + i); if (ObjectUtils.isEmpty(row2)) { @@ -318,7 +317,6 @@ public class SarFileCompareItemCommentServiceImpl extends ServiceImpl 0) { Row row2 = sheet.getRow(j + i); if (ObjectUtils.isEmpty(row2)) { @@ -409,21 +407,20 @@ public class SarFileCompareItemCommentServiceImpl extends ServiceImpl") < 0) { if (tableHtml.indexOf("") < 0) { tableHtml = tableHtml.replaceFirst("", ""); From 1bacc9ec5e6ea126e3aa5e345ae94499d08802d0 Mon Sep 17 00:00:00 2001 From: wangzhijiang <12345678> Date: Sun, 9 Oct 2022 15:32:55 +0800 Subject: [PATCH 015/251] =?UTF-8?q?uat=E9=97=AE=E9=A2=98=E4=BC=98=E5=8C=96?= =?UTF-8?q?-60796=E7=AC=AC=E4=B8=80=E6=9D=A1-=E6=B3=95=E8=A7=84=E6=8A=80?= =?UTF-8?q?=E6=9C=AF=E8=AF=84=E4=BC=B0-=E5=AF=BC=E5=85=A5=E6=9C=AC?= =?UTF-8?q?=E5=9C=B0=E6=8B=86=E8=A7=A3=E5=8D=95=EF=BC=8C=E6=9D=A1=E6=AC=BE?= =?UTF-8?q?=E5=90=8D=E7=A7=B0=E5=85=81=E8=AE=B8=E4=B8=BA=E7=A9=BA=E4=BF=AE?= =?UTF-8?q?=E6=94=B9=E3=80=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ...LawsTechnologyEvaluationEOServiceImpl.java | 21 +++++++------------ 1 file changed, 8 insertions(+), 13 deletions(-) diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/lawsTechnologyEvaluation/service/impl/LawsTechnologyEvaluationEOServiceImpl.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/lawsTechnologyEvaluation/service/impl/LawsTechnologyEvaluationEOServiceImpl.java index 567660c55..ac77d8994 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/lawsTechnologyEvaluation/service/impl/LawsTechnologyEvaluationEOServiceImpl.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/lawsTechnologyEvaluation/service/impl/LawsTechnologyEvaluationEOServiceImpl.java @@ -752,20 +752,15 @@ public class LawsTechnologyEvaluationEOServiceImpl extends ServiceImpl 100){ + if(StringUtils.equals(cut,CutEnum.CN.getValue())){ + errorMsg += "条款名称长度不能超过100;"; + }else if (StringUtils.equals(cut,CutEnum.EN.getValue())){ + errorMsg += "Item Name length of the cannot exceed 100;"; + } + countError++; } - countError++; - }else if(itemName.length() > 100){ - if(StringUtils.equals(cut,CutEnum.CN.getValue())){ - errorMsg += "条款名称长度不能超过100;"; - }else if (StringUtils.equals(cut,CutEnum.EN.getValue())){ - errorMsg += "Item Name length of the cannot exceed 100;"; - } - countError++; } if(StringUtils.isEmpty(itemContent)){ From 5fb59a91132b12eabcd096a9374dc6f7b47ac575 Mon Sep 17 00:00:00 2001 From: CD <1103614279@qq.com> Date: Sun, 9 Oct 2022 16:52:28 +0800 Subject: [PATCH 016/251] =?UTF-8?q?=E5=AF=B9=E5=A4=96=E6=8A=A5=E5=91=8A?= =?UTF-8?q?=E5=90=8C=E7=BA=A7=E6=96=B0=E5=A2=9E=E6=97=B6=E5=8A=A0=E5=88=A4?= =?UTF-8?q?=E6=96=AD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../controller/ExtRepoFolderController.java | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/extRepo/controller/ExtRepoFolderController.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/extRepo/controller/ExtRepoFolderController.java index 9e92f4c08..4a65703b0 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/extRepo/controller/ExtRepoFolderController.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/extRepo/controller/ExtRepoFolderController.java @@ -66,11 +66,20 @@ public class ExtRepoFolderController extends JeroController add(@Validated @RequestBody ExtRepoFolder extRepoFolder, HttpSession session) { Result result = new Result(); session.setAttribute("haveSuperiorManageAuth", false); - extRepoFolderService.haveSuperiorManageAuth(extRepoFolder.getSupFolder(),session); - if (ObjectUtils.isNotEmpty(session.getAttribute("haveSuperiorManageAuth"))&&(Boolean) session.getAttribute("haveSuperiorManageAuth")) { + ExtRepoFolder folder = extRepoFolderService.queryById(extRepoFolder.getSupFolder()); + extRepoFolderService.haveSuperiorManageAuth(folder.getSupFolder(),session); + //上层是否有权限 + boolean boo = (Boolean)session.getAttribute("haveSuperiorManageAuth"); + if (boo||extRepoFolderService.haveManageAuth(extRepoFolder.getSupFolder())) { if (!extRepoFolder.isAddSub()) { //增加同级文件夹 - ExtRepoFolder folder = extRepoFolderService.queryById(extRepoFolder.getSupFolder()); + if (!boo) { + if (CutEnum.CN.getValue().equals(extRepoFolder.getCut())) { + result.error500("没有父文件夹权限!"); + } else { + result.error500("You do not have parent folder permissions"); + } + } extRepoFolder.setSupFolder(folder.getSupFolder()); } extRepoFolderService.add(extRepoFolder); From 2f4b8d227971cf9f7ffa0733629288d02fac0ae6 Mon Sep 17 00:00:00 2001 From: CD <1103614279@qq.com> Date: Sun, 9 Oct 2022 16:55:02 +0800 Subject: [PATCH 017/251] =?UTF-8?q?=E5=B0=91=E4=B8=AA=EF=BC=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../modules/extRepo/controller/ExtRepoFolderController.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/extRepo/controller/ExtRepoFolderController.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/extRepo/controller/ExtRepoFolderController.java index 4a65703b0..1efcf4287 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/extRepo/controller/ExtRepoFolderController.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/extRepo/controller/ExtRepoFolderController.java @@ -77,7 +77,7 @@ public class ExtRepoFolderController extends JeroController Date: Sun, 9 Oct 2022 17:49:22 +0800 Subject: [PATCH 018/251] =?UTF-8?q?root=E4=B8=8D=E8=83=BD=E5=A2=9E?= =?UTF-8?q?=E5=8A=A0=E5=90=8C=E7=BA=A7?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../modules/extRepo/controller/ExtRepoFolderController.java | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/extRepo/controller/ExtRepoFolderController.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/extRepo/controller/ExtRepoFolderController.java index 1efcf4287..6feb16282 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/extRepo/controller/ExtRepoFolderController.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/extRepo/controller/ExtRepoFolderController.java @@ -4,6 +4,7 @@ import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; import com.jero.common.api.vo.Result; import com.jero.common.aspect.annotation.AutoLog; import com.jero.common.constant.enums.CutEnum; +import com.jero.common.exception.JeroBootException; import com.jero.common.system.base.controller.JeroController; import com.jero.modules.extRepo.entity.ERFTreeDataVO; import com.jero.modules.extRepo.entity.ExtRepoData; @@ -75,9 +76,9 @@ public class ExtRepoFolderController extends JeroController Date: Sun, 9 Oct 2022 17:56:11 +0800 Subject: [PATCH 019/251] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E7=A6=85=E9=81=93?= =?UTF-8?q?=E5=B7=B2=E7=9F=A5bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- jero-web/src/common/lang/en-us.js | 1 + jero-web/src/common/lang/zh-cn.js | 1 + .../components/RegulationMonthlyFill.vue | 2 +- .../components/modules/defaultTemplate.vue | 98 +++++++++++++------ .../components/modules/industryTemplate.vue | 24 +++++ .../components/TermInformation.vue | 11 ++- 6 files changed, 103 insertions(+), 34 deletions(-) diff --git a/jero-web/src/common/lang/en-us.js b/jero-web/src/common/lang/en-us.js index c1a20eec6..ee9098642 100644 --- a/jero-web/src/common/lang/en-us.js +++ b/jero-web/src/common/lang/en-us.js @@ -1317,4 +1317,5 @@ module.exports = { viewAll:'View All', endProcess:'End Process', thereForTheCurrentlySelectedData:'There is no standard breakdown for the currently selected data', + secondaryDirectory:'Secondary directory', } \ No newline at end of file diff --git a/jero-web/src/common/lang/zh-cn.js b/jero-web/src/common/lang/zh-cn.js index 6790de6e1..6c242520e 100644 --- a/jero-web/src/common/lang/zh-cn.js +++ b/jero-web/src/common/lang/zh-cn.js @@ -1418,4 +1418,5 @@ module.exports = { viewAll:'查看全部', endProcess:'结束流程', thereForTheCurrentlySelectedData:'当前所选数据暂无标准分解单', + secondaryDirectory:'二级目录', } \ No newline at end of file diff --git a/jero-web/src/views/businessSupport/regulationReport/components/RegulationMonthlyFill.vue b/jero-web/src/views/businessSupport/regulationReport/components/RegulationMonthlyFill.vue index 5fcdfcf2e..0fa66b3aa 100644 --- a/jero-web/src/views/businessSupport/regulationReport/components/RegulationMonthlyFill.vue +++ b/jero-web/src/views/businessSupport/regulationReport/components/RegulationMonthlyFill.vue @@ -144,7 +144,7 @@ width: 170 }, { - title: this.$t('chapterContents'), + title: this.$t('secondaryDirectory'), align: 'center', dataIndex: 'memoriesChapterName', ellipsis: true, diff --git a/jero-web/src/views/businessSupport/regulationReport/components/modules/defaultTemplate.vue b/jero-web/src/views/businessSupport/regulationReport/components/modules/defaultTemplate.vue index 9a91fe34f..b42ce13c7 100644 --- a/jero-web/src/views/businessSupport/regulationReport/components/modules/defaultTemplate.vue +++ b/jero-web/src/views/businessSupport/regulationReport/components/modules/defaultTemplate.vue @@ -4,8 +4,9 @@
- {{$t('title')}} + * + {{$t('title')}}
- {{$t('englishTitle')}} + * + {{$t('englishTitle')}}
- {{$t('technicalField')}} + * + {{$t('technicalField')}}
- +
- -
-
- {{$t('implementationModel')}} -
- - - -
-
+ + + + + + + + + + + + + + @@ -108,10 +111,10 @@ :title="$t('status')">{{$t('status')}}
-
@@ -125,9 +128,9 @@ :title="$t('usage')">{{$t('usage')}} - @@ -156,10 +159,11 @@ :title="$t('ImplementationDate')">{{$t('ImplementationDate')}} + + :placeholder="'202X.X.X'"/>
@@ -170,10 +174,11 @@ :title="$t('vehicleInProductionDate')">{{$t('vehicleInProductionDate')}} + + :placeholder="'202X.X.X'"/> @@ -185,6 +190,7 @@
+ * {{$t('primaryCoverageCn')}}
@@ -200,6 +206,7 @@
+ * {{$t('primaryCoverageEn')}}
@@ -245,9 +252,10 @@
+ * {{$t('regulatoryContact')}}
- +
+ * {{$t('title')}}
@@ -18,6 +19,7 @@
+ * {{$t('englishTitle')}}
@@ -110,6 +112,7 @@
+ * {{$t('primaryCoverageCn')}}
@@ -125,6 +128,7 @@
+ * {{$t('primaryCoverageEn')}}
@@ -165,6 +169,11 @@ return { rules: { titleCn: [ + { + required: true, + message: this.$t('title') + this.$t('cannotEmpty'), + trigger: 'blur' + }, { max: 500, message: this.$t('title') + this.$t('cannotExceed') + 500 + this.$t('Characters'), @@ -172,6 +181,11 @@ } ], titleEn: [ + { + required: true, + message: this.$t('englishTitle') + this.$t('cannotEmpty'), + trigger: 'blur' + }, { max: 500, message: this.$t('englishTitle') + this.$t('cannotExceed') + 500 + this.$t('Characters'), @@ -221,6 +235,11 @@ } ], contentEn: [ + { + required: true, + message: this.$t('primaryCoverageEn') + this.$t('cannotEmpty'), + trigger: 'blur' + }, { max: 300, message: this.$t('primaryCoverageEn') + this.$t('cannotExceed') + 300 + this.$t('Characters'), @@ -228,6 +247,11 @@ } ], contentCn: [ + { + required: true, + message: this.$t('primaryCoverageCn') + this.$t('cannotEmpty'), + trigger: 'blur' + }, { max: 300, message: this.$t('primaryCoverageCn') + this.$t('cannotExceed') + 300 + this.$t('Characters'), diff --git a/jero-web/src/views/businessSupport/technologyAssessment/components/TermInformation.vue b/jero-web/src/views/businessSupport/technologyAssessment/components/TermInformation.vue index 9e3374a4a..36d49be72 100644 --- a/jero-web/src/views/businessSupport/technologyAssessment/components/TermInformation.vue +++ b/jero-web/src/views/businessSupport/technologyAssessment/components/TermInformation.vue @@ -6,13 +6,14 @@ :visible="visible" :confirm-loading="confirmLoading" :maskClosable="false" + :footer="null" @cancel="visible = false" > - + + + + +
From 60e7133e658249f5aa707eff3912b913a0a9146c Mon Sep 17 00:00:00 2001 From: CD <1103614279@qq.com> Date: Sun, 9 Oct 2022 18:00:56 +0800 Subject: [PATCH 020/251] =?UTF-8?q?=E6=8F=90=E7=A4=BA=E8=AF=AD=E4=BF=AE?= =?UTF-8?q?=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../modules/extRepo/controller/ExtRepoFolderController.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/extRepo/controller/ExtRepoFolderController.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/extRepo/controller/ExtRepoFolderController.java index 6feb16282..c59e9f272 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/extRepo/controller/ExtRepoFolderController.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/extRepo/controller/ExtRepoFolderController.java @@ -76,9 +76,9 @@ public class ExtRepoFolderController extends JeroController Date: Sun, 9 Oct 2022 18:14:17 +0800 Subject: [PATCH 021/251] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E7=A6=85=E9=81=93?= =?UTF-8?q?=E5=B7=B2=E7=9F=A5bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/PersonnelSelection/index.vue | 640 +++++++++--------- 1 file changed, 320 insertions(+), 320 deletions(-) diff --git a/jero-web/src/components/PersonnelSelection/index.vue b/jero-web/src/components/PersonnelSelection/index.vue index 3d8bc49f8..9521fee72 100644 --- a/jero-web/src/components/PersonnelSelection/index.vue +++ b/jero-web/src/components/PersonnelSelection/index.vue @@ -32,39 +32,39 @@ v-model="searchModel" @search="onSearch"/>
{{$t('dataLoading')}} - + + + + + + + + + + + + + + + + + + + + - - - {{ data.title }} - - - - - - - - - - - - - - - - + checkable + checkStrictly + :loading="loading" + :tree-data="gData" + @check="onCheck" + @expand="onExpand" + v-model:checkedKeys="defaultCheckedKeys" + :defaultExpandedKeys="defaultExpandedKeys" + > +
{{$t('cancel')}} @@ -114,137 +114,137 @@ }, methods: { - checkChange(val, checked, indeterminate) { - if (!checked && this.searchData) { - this.userName = this.userName.filter(res => { - return res != val.title - }) - this.userIds = this.userIds.filter(res => { - return res != val.id - }) - for (let i = 0; i < this.userIds.length; i++) { - if (this.userIds[i] == val.parentId) { - this.userIds.splice(i, 1) - this.userName.splice(i, 1) - i-- - } - } - } else if (checked && this.searchData) { - this.userName.push(val.title) - this.userIds.push(val.id) - } - }, - handleCheckChange(val, data, checked) { - if (!this.searchData) { - this.userName = [] - this.userIds = [] - if (data.checkedNodes && data.checkedNodes.length > 0) { - data.checkedNodes.forEach(res => { - this.userName.push(res.title) - this.userIds.push(res.id) - }) - } - } - }, + // checkChange(val, checked, indeterminate) { + // if (!checked && this.searchData) { + // this.userName = this.userName.filter(res => { + // return res != val.title + // }) + // this.userIds = this.userIds.filter(res => { + // return res != val.id + // }) + // for (let i = 0; i < this.userIds.length; i++) { + // if (this.userIds[i] == val.parentId) { + // this.userIds.splice(i, 1) + // this.userName.splice(i, 1) + // i-- + // } + // } + // } else if (checked && this.searchData) { + // this.userName.push(val.title) + // this.userIds.push(val.id) + // } + // }, + // handleCheckChange(val, data, checked) { + // if (!this.searchData) { + // this.userName = [] + // this.userIds = [] + // if (data.checkedNodes && data.checkedNodes.length > 0) { + // data.checkedNodes.forEach(res => { + // this.userName.push(res.title) + // this.userIds.push(res.id) + // }) + // } + // } + // }, standardClick() { this.treeVisible = false - // this.departId = '' + this.departId = '' this.searchModel = '' this.searchData = '' - // this.userIds = [] - // this.userName = [] - // this.queryDepartUserTreeList(1) + this.userIds = [] + this.userName = [] + this.queryDepartUserTreeList(1) this.visible = true - let gData = localStorage.getItem('gData') - if (gData) { - let dataList = JSON.parse(gData) - if (!this.selectDepartment) { - dataList.forEach(res => { - if (res.type == 'Depart') { - res.disabled = true - } - }) - } - this.dataList = this.toTree(dataList) - } - setTimeout(() => { - if (gData) { - this.gData = this.dataList - this.gData = [...this.gData] - // this.treeVisible = true - if (this.personneQuery[this.query.db_field_name + 'Name']) { - this.userName = this.personneQuery[this.query.db_field_name + 'Name'].split(',') - } else if (this.personneQuery[this.query.db_field_name]) { - this.userName = this.personneQuery[this.query.db_field_name].split(',') - } else { - this.userName = [] - } - if (this.personneQuery[this.query.db_field_name + '_id']) { - this.userIds = this.personneQuery[this.query.db_field_name + '_id'].split(',') - } else if (this.personneQuery[this.query.db_field_name]) { - this.userIds = this.personneQuery[this.query.db_field_name].split(',') - } else { - this.userIds = [] - } - this.defaultCheckedKeys = this.userIds - this.defaultCheckedKeys = [...this.defaultCheckedKeys] - this.defaultExpandAll = false - this.treeVisible = true - } else { - this.queryDepartUserTreeList(1) - } - }, 200) - }, - deleteChildren(value, arr) { - let newarr = [] - arr.forEach(element => { - if (element.title.indexOf(value) > -1) { // 判断条件 - newarr.push(element) - } else { - if (element.children && element.children.length > 0) { - let redata = this.deleteChildren(value, element.children) - if (redata && redata.length > 0) { - let obj = { - ...element, - children: redata - } - newarr.push(obj) - } - } - } - }) - return newarr + // let gData = localStorage.getItem('gData') + // if (gData) { + // let dataList = JSON.parse(gData) + // if (!this.selectDepartment) { + // dataList.forEach(res => { + // if (res.type == 'Depart') { + // res.disabled = true + // } + // }) + // } + // this.dataList = this.toTree(dataList) + // } + // setTimeout(() => { + // if (gData) { + // this.gData = this.dataList + // this.gData = [...this.gData] + // // this.treeVisible = true + // if (this.personneQuery[this.query.db_field_name + 'Name']) { + // this.userName = this.personneQuery[this.query.db_field_name + 'Name'].split(',') + // } else if (this.personneQuery[this.query.db_field_name]) { + // this.userName = this.personneQuery[this.query.db_field_name].split(',') + // } else { + // this.userName = [] + // } + // if (this.personneQuery[this.query.db_field_name + '_id']) { + // this.userIds = this.personneQuery[this.query.db_field_name + '_id'].split(',') + // } else if (this.personneQuery[this.query.db_field_name]) { + // this.userIds = this.personneQuery[this.query.db_field_name].split(',') + // } else { + // this.userIds = [] + // } + // this.defaultCheckedKeys = this.userIds + // this.defaultCheckedKeys = [...this.defaultCheckedKeys] + // this.defaultExpandAll = false + // this.treeVisible = true + // } else { + // this.queryDepartUserTreeList(1) + // } + // }, 200) }, + // deleteChildren(value, arr) { + // let newarr = [] + // arr.forEach(element => { + // if (element.title.indexOf(value) > -1) { // 判断条件 + // newarr.push(element) + // } else { + // if (element.children && element.children.length > 0) { + // let redata = this.deleteChildren(value, element.children) + // if (redata && redata.length > 0) { + // let obj = { + // ...element, + // children: redata + // } + // newarr.push(obj) + // } + // } + // } + // }) + // return newarr + // }, //将数据拼成树形结构 - toTree(config, num) { - // 删除 所有 children,以防止多次调用 - config.forEach(function(item) { - delete item.children - }) - // 将数据存储为 以 id 为 KEY 的 map 索引数据列 - let map = {} - config.forEach((item) => { - item.label = item.name - item.key = item.id - - item.title = item.name + (item.itemName ? ' ' + item.itemName : '') - map[item.id] = item - }) - let val = [] - config.forEach((item) => { - // 以当前遍历项,的pid,去map对象中找到索引的id - let parent = map[item.parentId] - - // 如果找到索引,那么说明此项不在顶级当中,那么需要把此项添加到,他对应的父级中 - if (parent) { - (parent.children || (parent.children = [])).push(item) - } else { - //如果没有在map中找到对应的索引ID,那么直接把 当前的item添加到 val结果集中,作为顶级 - val.push(item) - } - }) - return val - }, + // toTree(config, num) { + // // 删除 所有 children,以防止多次调用 + // config.forEach(function(item) { + // delete item.children + // }) + // // 将数据存储为 以 id 为 KEY 的 map 索引数据列 + // let map = {} + // config.forEach((item) => { + // item.label = item.name + // item.key = item.id + // + // item.title = item.name + (item.itemName ? ' ' + item.itemName : '') + // map[item.id] = item + // }) + // let val = [] + // config.forEach((item) => { + // // 以当前遍历项,的pid,去map对象中找到索引的id + // let parent = map[item.parentId] + // + // // 如果找到索引,那么说明此项不在顶级当中,那么需要把此项添加到,他对应的父级中 + // if (parent) { + // (parent.children || (parent.children = [])).push(item) + // } else { + // //如果没有在map中找到对应的索引ID,那么直接把 当前的item添加到 val结果集中,作为顶级 + // val.push(item) + // } + // }) + // return val + // }, standardDelete() { this.$emit('input', null) this.$forceUpdate() @@ -255,61 +255,61 @@ // this.selectedKey = selectedKeys // }, - // onCheck(checkedKeys, info) { - // this.userIds = checkedKeys.checked - // this.userName = [] - // if (this.userIds.length > 0) { - // for (let i = 0; i < this.userIds.length; i++) { - // for (let j = 0; j < this.defaultCheckedKeysName.length; j++) { - // if (this.userIds[i] == this.defaultCheckedKeysName[j].id) { - // this.userName.push(this.defaultCheckedKeysName[j].name) - // } - // } - // } - // } - // if (info.checkedNodes && info.checkedNodes.length > 0) { - // info.checkedNodes.forEach(res => { - // if (res.data.props.dataRef.key) { - // this.content.push({ - // id: res.data.props.dataRef.key, - // title: res.data.props.dataRef.title - // }) - // } else { - // this.content.push({ - // id: res.data.props.id, - // title: res.data.props.title - // }) - // } - // }) - // } - // if (this.content && this.content.length > 0) { - // for (let i = 0; i < this.content.length; i++) { - // for (let j = i + 1; j < this.content.length; j++) { - // if (this.content[i].id == this.content[j].id) { - // this.content.splice(j, 1) - // j-- - // } - // } - // } - // this.userIds.forEach(res => { - // this.content.forEach(val => { - // if (res == val.id) { - // this.userName.push(val.title) - // } - // }) - // }) - // } - // if (this.userName.length > 0) { - // for (let i = 0; i < this.userName.length; i++) { - // for (let j = i + 1; j < this.userName.length; j++) { - // if (this.userName[i] == this.userName[j]) { - // this.userName.splice(j, 1) - // j-- - // } - // } - // } - // } - // }, + onCheck(checkedKeys, info) { + this.userIds = checkedKeys.checked + this.userName = [] + if (this.userIds.length > 0) { + for (let i = 0; i < this.userIds.length; i++) { + for (let j = 0; j < this.defaultCheckedKeysName.length; j++) { + if (this.userIds[i] == this.defaultCheckedKeysName[j].id) { + this.userName.push(this.defaultCheckedKeysName[j].name) + } + } + } + } + if (info.checkedNodes && info.checkedNodes.length > 0) { + info.checkedNodes.forEach(res => { + if (res.data.props.dataRef.key) { + this.content.push({ + id: res.data.props.dataRef.key, + title: res.data.props.dataRef.title + }) + } else { + this.content.push({ + id: res.data.props.id, + title: res.data.props.title + }) + } + }) + } + if (this.content && this.content.length > 0) { + for (let i = 0; i < this.content.length; i++) { + for (let j = i + 1; j < this.content.length; j++) { + if (this.content[i].id == this.content[j].id) { + this.content.splice(j, 1) + j-- + } + } + } + this.userIds.forEach(res => { + this.content.forEach(val => { + if (res == val.id) { + this.userName.push(val.title) + } + }) + }) + } + if (this.userName.length > 0) { + for (let i = 0; i < this.userName.length; i++) { + for (let j = i + 1; j < this.userName.length; j++) { + if (this.userName[i] == this.userName[j]) { + this.userName.splice(j, 1) + j-- + } + } + } + } + }, handleCancel() { this.visible = false this.treeVisible = false @@ -324,12 +324,12 @@ } let userIds = JSON.parse(JSON.stringify(this.userIds)) let userName = JSON.parse(JSON.stringify(this.userName)) - userName = userName.filter(function(item, index) { - return userName.indexOf(item) === index // 因为indexOf 只能查找到第一个 - }) - userIds = userIds.filter(function(item, index) { - return userIds.indexOf(item) === index // 因为indexOf 只能查找到第一个 - }) + // userName = userName.filter(function(item, index) { + // return userName.indexOf(item) === index // 因为indexOf 只能查找到第一个 + // }) + // userIds = userIds.filter(function(item, index) { + // return userIds.indexOf(item) === index // 因为indexOf 只能查找到第一个 + // }) this.$emit('input', userName.join(',')) this.$emit('change', this.query.db_field_name, userIds.join(','), this.query.subscript) this.visible = false @@ -347,119 +347,119 @@ this.defaultCheckedKeys = [] }, onSearch(e) { - this.treeVisible = false - let p = new Promise((resolve, reject) => { - resolve() + // this.treeVisible = false + // let p = new Promise((resolve, reject) => { + // resolve() + // }) + // p.then(() => { + // this.searchData = e + // let gData = localStorage.getItem('gData') + // let content = [] + // if (gData) { + // if (e) { + // JSON.parse(gData).forEach(res => { + // if (res.type == 'User') { + // if (res.name.includes(e)) { + // res.color = true + // content.push(res) + // } + // } + // // else if(res.type == 'Depart'){ + // // content.push(res) + // // } + // }) + // let gDataAdmin = this.toTree(content) + // this.gData = this.deleteChildren(e, gDataAdmin) + // this.defaultExpandAll = true + // this.treeVisible = true + // this.defaultCheckedKeys = this.userIds + // this.defaultCheckedKeys = [...this.defaultCheckedKeys] + // this.loading = false + // } else { + // let content = JSON.parse(gData) + // if (!this.selectDepartment) { + // content.forEach(res => { + // if (res.type == 'Depart') { + // res.disabled = true + // } + // }) + // } + // this.gData = this.toTree(content) + // this.defaultExpandAll = false + // this.defaultCheckedKeys = this.userIds + // this.defaultCheckedKeys = [...this.defaultCheckedKeys] + // this.treeVisible = true + // this.loading = false + // } + // } + // }) + this.gData = [] + this.departId = '' + this.visibleTree = false + if (e) { + this.getUserAndDepart() + } else { + this.treeVisible = false + this.queryDepartUserTreeList(2) + } + }, + getUserAndDepart() { + getAction('sys/user/getUserAndDepart', { name: this.searchModel }).then((res) => { + if (res) { + this.gData = res.filter(ele => ele.flag === 'DEPART') + } else { + this.gData = [] + } + this.visibleTree = true }) - p.then(() => { - this.searchData = e - let gData = localStorage.getItem('gData') - let content = [] - if (gData) { - if (e) { - JSON.parse(gData).forEach(res => { - if (res.type == 'User') { - if (res.name.includes(e)) { - res.color = true - content.push(res) - } - } - // else if(res.type == 'Depart'){ - // content.push(res) - // } - }) - let gDataAdmin = this.toTree(content) - this.gData = this.deleteChildren(e, gDataAdmin) - this.defaultExpandAll = true - this.treeVisible = true - this.defaultCheckedKeys = this.userIds - this.defaultCheckedKeys = [...this.defaultCheckedKeys] - this.loading = false + }, + onExpand(selectedKeys, val) { + if (this.searchModel == '' || !this.searchModel) { + if (val.expanded) { + if (this.departId == val.node.value) { } else { - let content = JSON.parse(gData) - if (!this.selectDepartment) { - content.forEach(res => { - if (res.type == 'Depart') { - res.disabled = true - } - }) - } - this.gData = this.toTree(content) - this.defaultExpandAll = false - this.defaultCheckedKeys = this.userIds - this.defaultCheckedKeys = [...this.defaultCheckedKeys] - this.treeVisible = true - this.loading = false + this.departId = val.node.value + this.queryDepartUserTreeList(2) } } - }) - // this.gData = [] - // this.departId = '' - // this.visibleTree = false - // if (e) { - // this.getUserAndDepart() - // } else { - // this.treeVisible = false - // this.queryDepartUserTreeList(2) - // } + } }, - // getUserAndDepart() { - // getAction('sys/user/getUserAndDepart', { name: this.searchModel }).then((res) => { - // if (res) { - // this.gData = res.filter(ele => ele.flag === 'DEPART') - // } else { - // this.gData = [] - // } - // this.visibleTree = true - // }) - // }, - // onExpand(selectedKeys, val) { - // if (this.searchModel == '' || !this.searchModel) { - // if (val.expanded) { - // if (this.departId == val.node.value) { - // } else { - // this.departId = val.node.value - // this.queryDepartUserTreeList(2) - // } - // } - // } - // }, queryDepartUserTreeList(num) { - // let gData = JSON.parse(JSON.stringify(this.gData)) - // if (gData && gData.length > 0) { - // gData = JSON.stringify(gData) - // } else { - // gData = '' - // } + let gData = JSON.parse(JSON.stringify(this.gData)) + if (gData && gData.length > 0) { + gData = JSON.stringify(gData) + } else { + gData = '' + } this.confirmLoading = true this.loading = true //queryDepartUserTreeList //queryUserTreeList - postAction('sys/user/queryUserTreeList', { - // departId: this.departId, - // json: gData, - // flag: '1' + postAction('sys/user/queryDepartUserTreeList', { + departId: this.departId, + json: gData, + flag: '1' }).then((res) => { this.confirmLoading = false if (res.success) { this.loading = false // localStorage.setItem('gData', JSON.stringify(res.result)) // this.toTree(dataList) - let content = JSON.parse(JSON.stringify(res.result)) - if (!this.selectDepartment) { - res.result.forEach(res => { - if (res.type == 'Depart') { - res.disabled = true - } - }) - } - localStorage.removeItem('gData') - localStorage.setItem('gData', JSON.stringify(content)) - this.gData = this.toTree(res.result) - // this.gData = res.result + // let content = JSON.parse(JSON.stringify(res.result)) + // if (!this.selectDepartment) { + // res.result.forEach(res => { + // if (res.type == 'Depart') { + // res.disabled = true + // } + // }) + // } + // localStorage.removeItem('gData') + // localStorage.setItem('gData', JSON.stringify(content)) + // this.gData = this.toTree(res.result) + this.gData = res.result this.gData = [...this.gData] // this.gData[0].isLeaf = false - // this.defaultExpandedKeys = [this.departId] + this.defaultExpandedKeys = [this.departId] if (num == 1) { if (this.userName && this.userName.length == 0) { if (this.personneQuery[this.query.db_field_name + 'Name']) { @@ -482,14 +482,14 @@ this.defaultCheckedKeys = this.userIds this.defaultCheckedKeys = [...this.defaultCheckedKeys] this.defaultCheckedKeysName = [] - // if (this.defaultCheckedKeys.length > 0) { - // for (let i = 0; i < this.defaultCheckedKeys.length; i++) { - // this.defaultCheckedKeysName.push({ - // id: this.defaultCheckedKeys[i], - // name: this.userName[i] - // }) - // } - // } + if (this.defaultCheckedKeys.length > 0) { + for (let i = 0; i < this.defaultCheckedKeys.length; i++) { + this.defaultCheckedKeysName.push({ + id: this.defaultCheckedKeys[i], + name: this.userName[i] + }) + } + } } this.defaultExpandAll = false this.treeVisible = true From 90b7701c66ebda2cf2843abdef52eace0a4b0dcb Mon Sep 17 00:00:00 2001 From: sunFlower <787203167@qq.com> Date: Sun, 9 Oct 2022 20:21:19 +0800 Subject: [PATCH 022/251] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E7=A6=85=E9=81=93?= =?UTF-8?q?=E5=B7=B2=E7=9F=A5bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/evaluationResultsWhole.vue | 79 +++++++++++++++---- 1 file changed, 65 insertions(+), 14 deletions(-) diff --git a/jero-web/src/views/businessSupport/technologyAssessment/components/evaluationResultsWhole.vue b/jero-web/src/views/businessSupport/technologyAssessment/components/evaluationResultsWhole.vue index cd25daf21..a57c1df23 100644 --- a/jero-web/src/views/businessSupport/technologyAssessment/components/evaluationResultsWhole.vue +++ b/jero-web/src/views/businessSupport/technologyAssessment/components/evaluationResultsWhole.vue @@ -39,22 +39,22 @@ -
-
- {{$t('engineer')+item.createBy+$t('feedbackResults')}} -
-
- {{$t('complianceResults')}}:{{item.complianceResultName}} -
-
+ + + + + + + + +
{{$t('fileExport')}}
+ { + const obj = { + children: value, + attrs: {} + } + if (index === 0) { + obj.attrs.rowSpan = row.indexData + } else { + obj.attrs.rowSpan = 0 + } + return obj + } + }, + { + title: this.$t('complianceResults'), + dataIndex: 'complianceResultName', + align: 'center', + width: 160, + ellipsis: true, + customRender: (value, row, index) => { + const obj = { + children: value, + attrs: {} + } + if (index === 0) { + obj.attrs.rowSpan = row.indexData + } else { + obj.attrs.rowSpan = 0 + } + return obj + } + }, { title: this.$t('relevantSections'), dataIndex: 'relatedSection', @@ -190,6 +228,18 @@ getAction(this.url.list, query).then((res) => { if (res.success) { this.dataSource = res.result || [] + if (this.dataSource && this.dataSource.length > 0) { + this.dataSource.forEach(val => { + if (val.lawsTechnologyEvaluationResultEOList && val.lawsTechnologyEvaluationResultEOList.length > 0) { + val.lawsTechnologyEvaluationResultEOList.forEach(ol => { + ol.indexData = val.lawsTechnologyEvaluationResultEOList.length + ol.complianceResultName = val.complianceResultName + ol.createBy = val.createBy + }) + } + }) + } + console.log(this.dataSource) if (this.dataSource.length == 0) { this.dataSource.push({ name: '' @@ -353,9 +403,10 @@ .table-operator-admin-right { float: left; - width: calc(100% - 240px); + width: 100%; text-align: right; - border-left: 1px solid #e8e8e8; + margin-bottom: 20px; + /*border-left: 1px solid #e8e8e8;*/ } .operator-text-index { From 1ec0784eb64033b8f0fbd051ae448d205da8d77f Mon Sep 17 00:00:00 2001 From: sunFlower <787203167@qq.com> Date: Sun, 9 Oct 2022 20:49:04 +0800 Subject: [PATCH 023/251] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E7=A6=85=E9=81=93?= =?UTF-8?q?=E5=B7=B2=E7=9F=A5bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- jero-web/src/components/viewFileModel/index.vue | 7 +++++-- .../components/countryCardView.vue | 7 +++++-- .../components/problemKnowledgeBaseListView.vue | 7 +++++-- .../components/RegulationMonthlyManagement.vue | 7 +++++-- .../components/monthlyReportRegulations.vue | 7 +++++-- .../documentManage/library/docDetail/index.vue | 7 +++++-- .../components/initiateComparison.vue | 7 +++++-- .../documentTools/documentComparison/index.vue | 13 +++++++++---- .../searchCenter/components/DocumentLibrary.vue | 7 +++++-- .../components/monthlyReportRegulations.vue | 13 +++++++++---- .../components/problemKnowledgeBase.vue | 7 +++++-- .../documentTools/searchCenter/components/whole.vue | 13 +++++++++---- .../virtualList/components/virtualListDetails.vue | 13 +++++++++---- .../components/standardContentList.vue | 13 +++++++++---- .../components/listOfRegulations.vue | 13 +++++++++---- .../components/resultReportedUpload.vue | 7 +++++-- .../projectManagement/historicalVersion/index.vue | 13 +++++++++---- 17 files changed, 113 insertions(+), 48 deletions(-) diff --git a/jero-web/src/components/viewFileModel/index.vue b/jero-web/src/components/viewFileModel/index.vue index 882c93446..19a707125 100644 --- a/jero-web/src/components/viewFileModel/index.vue +++ b/jero-web/src/components/viewFileModel/index.vue @@ -49,6 +49,7 @@ loading: false, visibleFile:false, downLoadFileUrl: window._CONFIG['domianPreviewURL'] + '/sys/common/download', + downLoadImgUrl: window._CONFIG['domianWebImgURL'] + '/sys/common/download', columnsFile: [ { title: this.$t('fileName'), @@ -78,10 +79,12 @@ } else if (fileSuffix == '.docx' || fileSuffix == '.doc') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + fileQuery.id + fileSuffix) window.open(url, '_blank') - } else if (fileSuffix == '.xlsx' || fileSuffix == '.xls' - || fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg') { + } else if (fileSuffix == '.xlsx' || fileSuffix == '.xls') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + fileQuery.id + fileSuffix) window.open(url, '_blank') + } else if(fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg'){ + let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadImgUrl + '/' + fileQuery.id + fileSuffix) + window.open(url, '_blank') } else { downloadFile('/sys/common/downLoadFile', fileQuery.fileName, { id: fileQuery.id }) } diff --git a/jero-web/src/views/businessSupport/problemKnowledgeBase/components/countryCardView.vue b/jero-web/src/views/businessSupport/problemKnowledgeBase/components/countryCardView.vue index dac938744..b851648ab 100644 --- a/jero-web/src/views/businessSupport/problemKnowledgeBase/components/countryCardView.vue +++ b/jero-web/src/views/businessSupport/problemKnowledgeBase/components/countryCardView.vue @@ -127,6 +127,7 @@ applyMarkets: '', header_text: '', downLoadFileUrl: window._CONFIG['domianPreviewURL'] + '/sys/common/download', + downLoadImgUrl: window._CONFIG['domianWebImgURL'] + '/sys/common/download', url: { list: '/problemKnowledgeBase/countryCardTempEO/list', deleteOne: '' @@ -153,10 +154,12 @@ } else if (fileSuffix == '.docx' || fileSuffix == '.doc') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + fileQuery.id + fileSuffix) window.open(url, '_blank') - } else if (fileSuffix == '.xlsx' || fileSuffix == '.xls' - || fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg') { + } else if (fileSuffix == '.xlsx' || fileSuffix == '.xls') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + fileQuery.id + fileSuffix) window.open(url, '_blank') + }else if(fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg'){ + let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadImgUrl + '/' + fileQuery.id + fileSuffix) + window.open(url, '_blank') } else { downloadFile('/sys/common/downLoadFile', fileQuery.contentFileName, { id: fileQuery.id }) } diff --git a/jero-web/src/views/businessSupport/problemKnowledgeBase/components/problemKnowledgeBaseListView.vue b/jero-web/src/views/businessSupport/problemKnowledgeBase/components/problemKnowledgeBaseListView.vue index 5c4fbfd08..6a4253db1 100644 --- a/jero-web/src/views/businessSupport/problemKnowledgeBase/components/problemKnowledgeBaseListView.vue +++ b/jero-web/src/views/businessSupport/problemKnowledgeBase/components/problemKnowledgeBaseListView.vue @@ -200,6 +200,7 @@ queryForm: {}, isPraise: false, downLoadFileUrl: window._CONFIG['domianPreviewURL'] + '/sys/common/download', + downLoadImgUrl: window._CONFIG['domianWebImgURL'] + '/sys/common/download', isCollect: false } }, @@ -218,10 +219,12 @@ } else if (fileSuffix == '.docx' || fileSuffix == '.doc') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + fileQuery.id + fileSuffix) window.open(url, '_blank') - } else if (fileSuffix == '.xlsx' || fileSuffix == '.xls' - || fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg') { + } else if (fileSuffix == '.xlsx' || fileSuffix == '.xls') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + fileQuery.id + fileSuffix) window.open(url, '_blank') + }else if(fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg'){ + let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadImgUrl + '/' + fileQuery.id + fileSuffix) + window.open(url, '_blank') } else { downloadFile('/sys/common/downLoadFile', fileQuery.fileName, { id: fileQuery.id }) } diff --git a/jero-web/src/views/businessSupport/regulationReport/components/RegulationMonthlyManagement.vue b/jero-web/src/views/businessSupport/regulationReport/components/RegulationMonthlyManagement.vue index 67a9a1ca8..09ff3b0f0 100644 --- a/jero-web/src/views/businessSupport/regulationReport/components/RegulationMonthlyManagement.vue +++ b/jero-web/src/views/businessSupport/regulationReport/components/RegulationMonthlyManagement.vue @@ -108,6 +108,7 @@ pageNo: 1, queryParam: {}, downLoadFileUrl: window._CONFIG['domianPreviewURL'] + '/sys/common/download', + downLoadImgUrl: window._CONFIG['domianWebImgURL'] + '/sys/common/download', userData: {}, columns: [ { @@ -216,10 +217,12 @@ } else if (fileSuffix === '.docx' || fileSuffix === '.doc') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + item.fileId + fileSuffix) window.open(url, '_blank') - } else if (fileSuffix === '.xlsx' || fileSuffix === '.xls' - || fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg') { + } else if (fileSuffix === '.xlsx' || fileSuffix === '.xls') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + item.fileId + fileSuffix) window.open(url, '_blank') + }else if(fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg'){ + let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadImgUrl + '/' + item.fileId + fileSuffix) + window.open(url, '_blank') } else { if (item.createBy == this.userInfo().username) { downloadFile('/sys/common/downLoadFile', item.name, { id: item.fileId, userName: this.userInfo().username }) diff --git a/jero-web/src/views/dashboard/components/monthlyReportRegulations.vue b/jero-web/src/views/dashboard/components/monthlyReportRegulations.vue index 96f62e53f..7955c1749 100644 --- a/jero-web/src/views/dashboard/components/monthlyReportRegulations.vue +++ b/jero-web/src/views/dashboard/components/monthlyReportRegulations.vue @@ -33,6 +33,7 @@ monthlyReportRegulationsList: [], loading: false, downLoadFileUrl: window._CONFIG['domianPreviewURL'] + '/sys/common/download', + downLoadImgUrl: window._CONFIG['domianWebImgURL'] + '/sys/common/download', url: { list: '/report/lawsMonthlyReportManageEO/page' } @@ -74,10 +75,12 @@ } else if (fileSuffix === '.docx' || fileSuffix === '.doc') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + item.fileId + fileSuffix) window.open(url, '_blank') - } else if (fileSuffix === '.xlsx' || fileSuffix === '.xls' - || fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg') { + } else if (fileSuffix === '.xlsx' || fileSuffix === '.xls') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + item.fileId + fileSuffix) window.open(url, '_blank') + }else if(fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg'){ + let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadImgUrl + '/' + item.fileId + fileSuffix) + window.open(url, '_blank') } else { if (item.createBy == this.userInfo().username){ downloadFile('/sys/common/downLoadFile', item.name, { id: item.fileId, userName: this.userInfo().username }) diff --git a/jero-web/src/views/documentManage/library/docDetail/index.vue b/jero-web/src/views/documentManage/library/docDetail/index.vue index 0fc6f949e..8f770354b 100644 --- a/jero-web/src/views/documentManage/library/docDetail/index.vue +++ b/jero-web/src/views/documentManage/library/docDetail/index.vue @@ -319,6 +319,7 @@ serial_number: '', confirmLoading: false, downLoadFileUrl: window._CONFIG['domianPreviewURL'] + '/sys/common/download', + downLoadImgUrl: window._CONFIG['domianWebImgURL'] + '/sys/common/download', loading: false, dataSource: [], pageNo: 1, @@ -462,10 +463,12 @@ } else if (fileSuffix == '.docx' || fileSuffix == '.doc') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + fileQuery.id + fileSuffix) window.open(url, '_blank') - } else if (fileSuffix == '.xlsx' || fileSuffix == '.xls' - || fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg') { + } else if (fileSuffix == '.xlsx' || fileSuffix == '.xls') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + fileQuery.id + fileSuffix) window.open(url, '_blank') + }else if(fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg'){ + let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadImgUrl + '/' + fileQuery.id + fileSuffix) + window.open(url, '_blank') } else { downloadFile('/sys/common/downLoadFile', fileQuery.fileName, { id: fileQuery.id }) } diff --git a/jero-web/src/views/documentTools/documentComparison/components/initiateComparison.vue b/jero-web/src/views/documentTools/documentComparison/components/initiateComparison.vue index f110bf30f..7375c90ee 100644 --- a/jero-web/src/views/documentTools/documentComparison/components/initiateComparison.vue +++ b/jero-web/src/views/documentTools/documentComparison/components/initiateComparison.vue @@ -196,6 +196,7 @@ pageNoRight: 1, formInline: {}, downLoadFileUrl: window._CONFIG['domianPreviewURL'] + '/sys/common/download', + downLoadImgUrl: window._CONFIG['domianWebImgURL'] + '/sys/common/download', rules: { remark: [ { @@ -388,10 +389,12 @@ } else if (fileSuffix == '.docx' || fileSuffix == '.doc') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + fileQuery.fileId + fileSuffix) window.open(url, '_blank') - } else if (fileSuffix == '.xlsx' || fileSuffix == '.xls' - || fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg') { + } else if (fileSuffix == '.xlsx' || fileSuffix == '.xls') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + fileQuery.fileId + fileSuffix) window.open(url, '_blank') + }else if(fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg'){ + let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadImgUrl + '/' + fileQuery.fileId + fileSuffix) + window.open(url, '_blank') } else { downloadFile('/sys/common/downLoadFile', fileQuery.fileName, { id: fileQuery.fileId }) } diff --git a/jero-web/src/views/documentTools/documentComparison/index.vue b/jero-web/src/views/documentTools/documentComparison/index.vue index 0db7f9fde..39fe0ee88 100644 --- a/jero-web/src/views/documentTools/documentComparison/index.vue +++ b/jero-web/src/views/documentTools/documentComparison/index.vue @@ -126,6 +126,7 @@ dataSource: [], selectedRowKeys: [], downLoadFileUrl: window._CONFIG['domianPreviewURL'] + '/sys/common/download', + downLoadImgUrl: window._CONFIG['domianWebImgURL'] + '/sys/common/download', total: 0, pageSize: 10, pageNo: 1, @@ -422,10 +423,12 @@ } else if (fileSuffix === '.docx' || fileSuffix === '.doc') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + row.fileIdLeft + fileSuffix) window.open(url, '_blank') - } else if (fileSuffix === '.xlsx' || fileSuffix === '.xls' - || fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg') { + } else if (fileSuffix === '.xlsx' || fileSuffix === '.xls') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + row.fileIdLeft + fileSuffix) window.open(url, '_blank') + }else if(fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg'){ + let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadImgUrl + '/' + row.fileIdLeft + fileSuffix) + window.open(url, '_blank') } else { downloadFile('/sys/common/downLoadFile', row.fileNameLeft, { id: row.fileIdLeft }) } @@ -440,10 +443,12 @@ } else if (fileSuffix === '.docx' || fileSuffix === '.doc') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + row.fileIdRight + fileSuffix) window.open(url, '_blank') - } else if (fileSuffix === '.xlsx' || fileSuffix === '.xls' - || fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg') { + } else if (fileSuffix === '.xlsx' || fileSuffix === '.xls') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + row.fileIdRight + fileSuffix) window.open(url, '_blank') + }else if(fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg'){ + let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadImgUrl + '/' + row.fileIdRight + fileSuffix) + window.open(url, '_blank') } else { downloadFile('/sys/common/downLoadFile', row.fileNameRight, { id: row.fileIdRight }) } diff --git a/jero-web/src/views/documentTools/searchCenter/components/DocumentLibrary.vue b/jero-web/src/views/documentTools/searchCenter/components/DocumentLibrary.vue index 176ad2d8e..586d54b97 100644 --- a/jero-web/src/views/documentTools/searchCenter/components/DocumentLibrary.vue +++ b/jero-web/src/views/documentTools/searchCenter/components/DocumentLibrary.vue @@ -352,6 +352,7 @@ selectModel: '', fileList: [], downLoadFileUrl: window._CONFIG['domianPreviewURL'] + '/sys/common/download', + downLoadImgUrl: window._CONFIG['domianWebImgURL'] + '/sys/common/download', queryParamSeach: '', mapOne: {}, mapTwo: {}, @@ -696,10 +697,12 @@ } else if (fileSuffix == '.docx' || fileSuffix == '.doc') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + fileQuery.id + fileSuffix) window.open(url, '_blank') - } else if (fileSuffix == '.xlsx' || fileSuffix == '.xls' - || fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg') { + } else if (fileSuffix == '.xlsx' || fileSuffix == '.xls') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + fileQuery.id + fileSuffix) window.open(url, '_blank') + }else if(fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg'){ + let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadImgUrl + '/' + fileQuery.id + fileSuffix) + window.open(url, '_blank') } else { downloadFile('/sys/common/downLoadFile', fileQuery.fileName || fileQuery.file_name, { id: fileQuery.id }) } diff --git a/jero-web/src/views/documentTools/searchCenter/components/monthlyReportRegulations.vue b/jero-web/src/views/documentTools/searchCenter/components/monthlyReportRegulations.vue index 4983ee2fc..a5ce3f338 100644 --- a/jero-web/src/views/documentTools/searchCenter/components/monthlyReportRegulations.vue +++ b/jero-web/src/views/documentTools/searchCenter/components/monthlyReportRegulations.vue @@ -92,6 +92,7 @@ total: 0, pageSize: 10, downLoadFileUrl: window._CONFIG['domianPreviewURL'] + '/sys/common/download', + downLoadImgUrl: window._CONFIG['domianWebImgURL'] + '/sys/common/download', pageNo: 1, queryParam: {} } @@ -129,10 +130,12 @@ } else if (fileSuffix == '.docx' || fileSuffix == '.doc') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + item.file_id + fileSuffix) window.open(url, '_blank') - } else if (fileSuffix == '.xlsx' || fileSuffix == '.xls' - || fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg') { + } else if (fileSuffix == '.xlsx' || fileSuffix == '.xls') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + item.file_id + fileSuffix) window.open(url, '_blank') + }else if(fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg'){ + let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadImgUrl + '/' + item.file_id + fileSuffix) + window.open(url, '_blank') } }, ResetSearch() { @@ -151,10 +154,12 @@ } else if (fileSuffix == '.docx' || fileSuffix == '.doc') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + fileQuery.id.slice(0, 32) + fileSuffix) window.open(url, '_blank') - } else if (fileSuffix == '.xlsx' || fileSuffix == '.xls' - || fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg') { + } else if (fileSuffix == '.xlsx' || fileSuffix == '.xls') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + fileQuery.id.slice(0, 32) + fileSuffix) window.open(url, '_blank') + }else if(fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg'){ + let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadImgUrl + '/' + fileQuery.id.slice(0, 32) + fileSuffix) + window.open(url, '_blank') } else { downloadFile('/sys/common/downLoadFile', fileQuery.file_name, { id: fileQuery.id.slice(0, 32) }) } diff --git a/jero-web/src/views/documentTools/searchCenter/components/problemKnowledgeBase.vue b/jero-web/src/views/documentTools/searchCenter/components/problemKnowledgeBase.vue index 13b476153..ea2577782 100644 --- a/jero-web/src/views/documentTools/searchCenter/components/problemKnowledgeBase.vue +++ b/jero-web/src/views/documentTools/searchCenter/components/problemKnowledgeBase.vue @@ -132,6 +132,7 @@ loading: false, fileList: [], downLoadFileUrl: window._CONFIG['domianPreviewURL'] + '/sys/common/download', + downLoadImgUrl: window._CONFIG['domianWebImgURL'] + '/sys/common/download', mapOne: {}, mapTwo: {}, queryParamOne: {}, @@ -267,10 +268,12 @@ } else if (fileSuffix == '.docx' || fileSuffix == '.doc') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + fileQuery.id + fileSuffix) window.open(url, '_blank') - } else if (fileSuffix == '.xlsx' || fileSuffix == '.xls' - || fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg') { + } else if (fileSuffix == '.xlsx' || fileSuffix == '.xls') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + fileQuery.id + fileSuffix) window.open(url, '_blank') + }else if(fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg'){ + let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadImgUrl + '/' + fileQuery.id + fileSuffix) + window.open(url, '_blank') } else { downloadFile('/sys/common/downLoadFile', fileQuery.fileName || fileQuery.file_name, { id: fileQuery.id }) } diff --git a/jero-web/src/views/documentTools/searchCenter/components/whole.vue b/jero-web/src/views/documentTools/searchCenter/components/whole.vue index b59a97b57..4b5525064 100644 --- a/jero-web/src/views/documentTools/searchCenter/components/whole.vue +++ b/jero-web/src/views/documentTools/searchCenter/components/whole.vue @@ -116,6 +116,7 @@ total: 0, pageSize: 10, downLoadFileUrl: window._CONFIG['domianPreviewURL'] + '/sys/common/download', + downLoadImgUrl: window._CONFIG['domianWebImgURL'] + '/sys/common/download', pageNo: 1, queryParam: {} } @@ -170,10 +171,12 @@ } else if (fileSuffix == '.docx' || fileSuffix == '.doc') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + fileQuery.id.slice(0, 32) + fileSuffix) window.open(url, '_blank') - } else if (fileSuffix == '.xlsx' || fileSuffix == '.xls' - || fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg') { + } else if (fileSuffix == '.xlsx' || fileSuffix == '.xls') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + fileQuery.id.slice(0, 32) + fileSuffix) window.open(url, '_blank') + }else if(fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg'){ + let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadImgUrl + '/' + fileQuery.id.slice(0, 32) + fileSuffix) + window.open(url, '_blank') } else { downloadFile('/sys/common/downLoadFile', fileQuery.file_name, { id: fileQuery.id.slice(0, 32) }) } @@ -239,10 +242,12 @@ } else if (fileSuffix == '.docx' || fileSuffix == '.doc') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + item.file_id + fileSuffix) window.open(url, '_blank') - } else if (fileSuffix == '.xlsx' || fileSuffix == '.xls' - || fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg') { + } else if (fileSuffix == '.xlsx' || fileSuffix == '.xls') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + item.file_id + fileSuffix) window.open(url, '_blank') + }else if(fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg'){ + let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadImgUrl + '/' + item.file_id + fileSuffix) + window.open(url, '_blank') } }, titleClick(item) { diff --git a/jero-web/src/views/documentTools/virtualList/components/virtualListDetails.vue b/jero-web/src/views/documentTools/virtualList/components/virtualListDetails.vue index 115752b3a..ffad9f9d9 100644 --- a/jero-web/src/views/documentTools/virtualList/components/virtualListDetails.vue +++ b/jero-web/src/views/documentTools/virtualList/components/virtualListDetails.vue @@ -279,6 +279,7 @@ components: {}, visibleFile: false, downLoadFileUrl: window._CONFIG['domianPreviewURL'] + '/sys/common/download', + downLoadImgUrl: window._CONFIG['domianWebImgURL'] + '/sys/common/download', dataSourceFile: [], columnsFile: [ { @@ -830,10 +831,12 @@ } else if (fileSuffix == '.docx' || fileSuffix == '.doc') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + fileQuery.id + fileSuffix) window.open(url, '_blank') - } else if (fileSuffix == '.xlsx' || fileSuffix == '.xls' - || fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg') { + } else if (fileSuffix == '.xlsx' || fileSuffix == '.xls') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + fileQuery.id + fileSuffix) window.open(url, '_blank') + }else if(fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg'){ + let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadImgUrl + '/' + fileQuery.id + fileSuffix) + window.open(url, '_blank') } else { downloadFile('/sys/common/downLoadFile', fileQuery.fileName, { id: fileQuery.id }) } @@ -848,10 +851,12 @@ } else if (fileSuffix == '.docx' || fileSuffix == '.doc') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + id + fileSuffix) window.open(url, '_blank') - } else if (fileSuffix == '.xlsx' || fileSuffix == '.xls' - || fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg') { + } else if (fileSuffix == '.xlsx' || fileSuffix == '.xls') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + id + fileSuffix) window.open(url, '_blank') + }else if(fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg'){ + let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadImgUrl + '/' + id + fileSuffix) + window.open(url, '_blank') } else { downloadFile('/sys/common/downLoadFile', name, { id: id }) } diff --git a/jero-web/src/views/processCenter/components/standardContentList.vue b/jero-web/src/views/processCenter/components/standardContentList.vue index dcc984c20..32fd02fd5 100644 --- a/jero-web/src/views/processCenter/components/standardContentList.vue +++ b/jero-web/src/views/processCenter/components/standardContentList.vue @@ -71,6 +71,7 @@ return { dataSource: [], downLoadFileUrl: window._CONFIG['domianPreviewURL'] + '/sys/common/download', + downLoadImgUrl: window._CONFIG['domianWebImgURL'] + '/sys/common/download', columns: [ { title: this.$t('ProcessType'), @@ -187,10 +188,12 @@ } else if (fileSuffix == '.docx' || fileSuffix == '.doc') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + fileQuery.id + fileSuffix) window.open(url, '_blank') - } else if (fileSuffix == '.xlsx' || fileSuffix == '.xls' - || fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg') { + } else if (fileSuffix == '.xlsx' || fileSuffix == '.xls') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + fileQuery.id + fileSuffix) window.open(url, '_blank') + }else if(fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg'){ + let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadImgUrl + '/' + fileQuery.id + fileSuffix) + window.open(url, '_blank') } else { downloadFile('/sys/common/downLoadFile', fileQuery.fileName, { id: fileQuery.id }) } @@ -205,10 +208,12 @@ } else if (fileSuffix == '.docx' || fileSuffix == '.doc') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + id + fileSuffix) window.open(url, '_blank') - } else if (fileSuffix == '.xlsx' || fileSuffix == '.xls' - || fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg') { + } else if (fileSuffix == '.xlsx' || fileSuffix == '.xls') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + id + fileSuffix) window.open(url, '_blank') + }else if(fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg'){ + let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadImgUrl + '/' + id + fileSuffix) + window.open(url, '_blank') } else { downloadFile('/sys/common/downLoadFile', name, { id: id }) } diff --git a/jero-web/src/views/projectManagement/components/listOfRegulations.vue b/jero-web/src/views/projectManagement/components/listOfRegulations.vue index b2b6e72b1..ca9de26a5 100644 --- a/jero-web/src/views/projectManagement/components/listOfRegulations.vue +++ b/jero-web/src/views/projectManagement/components/listOfRegulations.vue @@ -848,6 +848,7 @@ AndUserIdEdit: '/project/projectLibraryRoleRelEO/edit' }, downLoadFileUrl: window._CONFIG['domianPreviewURL'] + '/sys/common/download', + downLoadImgUrl: window._CONFIG['domianWebImgURL'] + '/sys/common/download', loading: false, dataSource: [], isResultReported: false, @@ -2126,10 +2127,12 @@ } else if (fileSuffix == '.docx' || fileSuffix == '.doc') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + fileQuery.id + fileSuffix) window.open(url, '_blank') - } else if (fileSuffix == '.xlsx' || fileSuffix == '.xls' - || fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg') { + } else if (fileSuffix == '.xlsx' || fileSuffix == '.xls') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + fileQuery.id + fileSuffix) window.open(url, '_blank') + }else if(fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg'){ + let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadImgUrl + '/' + fileQuery.id + fileSuffix) + window.open(url, '_blank') } else { downloadFile('/sys/common/downLoadFile', fileQuery.fileName, { id: fileQuery.id }) } @@ -2145,10 +2148,12 @@ } else if (fileSuffix == '.docx' || fileSuffix == '.doc') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + id + fileSuffix) window.open(url, '_blank') - } else if (fileSuffix == '.xlsx' || fileSuffix == '.xls' - || fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg') { + } else if (fileSuffix == '.xlsx' || fileSuffix == '.xls') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + id + fileSuffix) window.open(url, '_blank') + }else if(fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg'){ + let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadImgUrl + '/' + id + fileSuffix) + window.open(url, '_blank') } else { downloadFile('/sys/common/downLoadFile', name, { id: id, userName: this.userInfo().username }) } diff --git a/jero-web/src/views/projectManagement/components/resultReportedUpload.vue b/jero-web/src/views/projectManagement/components/resultReportedUpload.vue index 034fd3e96..a45c9d3a3 100644 --- a/jero-web/src/views/projectManagement/components/resultReportedUpload.vue +++ b/jero-web/src/views/projectManagement/components/resultReportedUpload.vue @@ -49,6 +49,7 @@ myuploadAction: window._CONFIG['domianURL'] + this.thisFileUploadUrl, upDataList: [], downLoadFileUrl: window._CONFIG['domianPreviewURL'] + '/sys/common/download', + downLoadImgUrl: window._CONFIG['domianWebImgURL'] + '/sys/common/download', fileList: [], myfileList: [], isLoding: false, @@ -214,10 +215,12 @@ } else if (fileSuffix === '.docx' || fileSuffix === '.doc') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + fileQuery.id + fileSuffix) window.open(url, '_blank') - } else if (fileSuffix === '.xlsx' || fileSuffix === '.xls' - || fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg') { + } else if (fileSuffix === '.xlsx' || fileSuffix === '.xls') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + fileQuery.id + fileSuffix) window.open(url, '_blank') + }else if(fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg'){ + let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadImgUrl + '/' + fileQuery.id + fileSuffix) + window.open(url, '_blank') } else { downloadFile('/sys/common/downLoadFile', fileQuery.fileName, { id: fileQuery.id,userName:this.userInfo().username }) } diff --git a/jero-web/src/views/projectManagement/historicalVersion/index.vue b/jero-web/src/views/projectManagement/historicalVersion/index.vue index e6e932166..a2ce6ffa2 100644 --- a/jero-web/src/views/projectManagement/historicalVersion/index.vue +++ b/jero-web/src/views/projectManagement/historicalVersion/index.vue @@ -363,6 +363,7 @@ list: '/project/projectVersionInfoEO/list' }, downLoadFileUrl: window._CONFIG['domianPreviewURL'] + '/sys/common/download', + downLoadImgUrl: window._CONFIG['domianWebImgURL'] + '/sys/common/download', loading: false, dataSource: [], // fieldList | array |✔| 需要查询的列集合示例如下,type类型有:date/datetime/string/int/number @@ -468,10 +469,12 @@ } else if (fileSuffix == '.docx' || fileSuffix == '.doc') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + fileQuery.id + fileSuffix) window.open(url, '_blank') - } else if (fileSuffix == '.xlsx' || fileSuffix == '.xls' - || fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg') { + } else if (fileSuffix == '.xlsx' || fileSuffix == '.xls') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + fileQuery.id + fileSuffix) window.open(url, '_blank') + }else if(fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg'){ + let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadImgUrl + '/' + fileQuery.id + fileSuffix) + window.open(url, '_blank') } else { downloadFile('/sys/common/downLoadFile', fileQuery.fileName, { id: fileQuery.id }) } @@ -486,10 +489,12 @@ } else if (fileSuffix == '.docx' || fileSuffix == '.doc') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + id + fileSuffix) window.open(url, '_blank') - } else if (fileSuffix == '.xlsx' || fileSuffix == '.xls' - || fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg') { + } else if (fileSuffix == '.xlsx' || fileSuffix == '.xls') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + id + fileSuffix) window.open(url, '_blank') + }else if(fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg'){ + let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadImgUrl + '/' + id + fileSuffix) + window.open(url, '_blank') } else { downloadFile('/sys/common/downLoadFile', name, { id: id }) } From 62a87236aa42063812ba59665489a08f5db4690f Mon Sep 17 00:00:00 2001 From: CD <1103614279@qq.com> Date: Mon, 10 Oct 2022 10:21:57 +0800 Subject: [PATCH 024/251] =?UTF-8?q?=E6=96=B9=E6=B3=95=E5=90=8D=E7=A7=B0?= =?UTF-8?q?=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../SarFileCompareItemCommentServiceImpl.java | 25 ++++++++++--------- 1 file changed, 13 insertions(+), 12 deletions(-) diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/service/impl/SarFileCompareItemCommentServiceImpl.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/service/impl/SarFileCompareItemCommentServiceImpl.java index a635115b7..d54fc7199 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/service/impl/SarFileCompareItemCommentServiceImpl.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/service/impl/SarFileCompareItemCommentServiceImpl.java @@ -288,9 +288,9 @@ public class SarFileCompareItemCommentServiceImpl extends ServiceImpl") < 0) { @@ -487,7 +487,7 @@ public class SarFileCompareItemCommentServiceImpl extends ServiceImpl", "").replace("

", "\r\n"); //分割图片 - addImgdata(text, request.getSession()); + splitImg(text, request.getSession()); //分割表格 String txtAndImg = (String) request.getSession().getAttribute("txtAndImg"); txtAndImg = txtAndImg.replaceAll("table", "replaceTable"); @@ -514,18 +514,19 @@ public class SarFileCompareItemCommentServiceImpl extends ServiceImpl标签内容中的图片路径,并重新按顺序拼接 + * 分割图片 * @param text + * @param session * @return */ - private void addImgdata(String text,HttpSession session) { + private void splitImg(String text,HttpSession session) { if (text.contains("") + 3); String img = text.substring(text.indexOf("")); String path = img.substring(img.lastIndexOf("=") + 1)+"g"; text = txtLeft + "---" + path + "---" + txtRight; - addImgdata(text, session); + splitImg(text, session); } else { session.setAttribute("txtAndImg", text); } From c906c3556672e78c787c370bc7d9282a378155af Mon Sep 17 00:00:00 2001 From: sunFlower <787203167@qq.com> Date: Mon, 10 Oct 2022 10:22:01 +0800 Subject: [PATCH 025/251] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E7=A6=85=E9=81=93?= =?UTF-8?q?=E5=B7=B2=E7=9F=A5bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- jero-web/src/common/lang/en-us.js | 1 + jero-web/src/common/lang/zh-cn.js | 1 + .../components/PersonnelSelection/index.vue | 653 +++++++++--------- 3 files changed, 331 insertions(+), 324 deletions(-) diff --git a/jero-web/src/common/lang/en-us.js b/jero-web/src/common/lang/en-us.js index ee9098642..cb6a0ad64 100644 --- a/jero-web/src/common/lang/en-us.js +++ b/jero-web/src/common/lang/en-us.js @@ -1318,4 +1318,5 @@ module.exports = { endProcess:'End Process', thereForTheCurrentlySelectedData:'There is no standard breakdown for the currently selected data', secondaryDirectory:'Secondary directory', + OnlyPersonsCanBeSelected:'The maximum upper limit is exceeded; Only 100 persons can be selected', } \ No newline at end of file diff --git a/jero-web/src/common/lang/zh-cn.js b/jero-web/src/common/lang/zh-cn.js index 6c242520e..28ce6b3c9 100644 --- a/jero-web/src/common/lang/zh-cn.js +++ b/jero-web/src/common/lang/zh-cn.js @@ -1419,4 +1419,5 @@ module.exports = { endProcess:'结束流程', thereForTheCurrentlySelectedData:'当前所选数据暂无标准分解单', secondaryDirectory:'二级目录', + OnlyPersonsCanBeSelected:'超出最大上限;只能选择100个人员', } \ No newline at end of file diff --git a/jero-web/src/components/PersonnelSelection/index.vue b/jero-web/src/components/PersonnelSelection/index.vue index 9521fee72..b84f99147 100644 --- a/jero-web/src/components/PersonnelSelection/index.vue +++ b/jero-web/src/components/PersonnelSelection/index.vue @@ -32,39 +32,39 @@ v-model="searchModel" @search="onSearch"/>
{{$t('dataLoading')}} - - - - - - - - - - - - - - - - - - - - - - + ref="virtualNodeTreeRef" + :keeps="40" + show-checkbox + v-model="checkboxList" + class="treeWrap" + :defaultCheckedKeys="defaultCheckedKeys" + :defaultExpandAll="defaultExpandAll" + :check-strictly="false" + node-key="id" + @check="handleCheckChange" + @check-change="checkChange" + :data.sync="gData"> + + + {{ data.title }} + + + + + + + + + + + + + + + +
{{$t('cancel')}} @@ -114,137 +114,137 @@ }, methods: { - // checkChange(val, checked, indeterminate) { - // if (!checked && this.searchData) { - // this.userName = this.userName.filter(res => { - // return res != val.title - // }) - // this.userIds = this.userIds.filter(res => { - // return res != val.id - // }) - // for (let i = 0; i < this.userIds.length; i++) { - // if (this.userIds[i] == val.parentId) { - // this.userIds.splice(i, 1) - // this.userName.splice(i, 1) - // i-- - // } - // } - // } else if (checked && this.searchData) { - // this.userName.push(val.title) - // this.userIds.push(val.id) - // } - // }, - // handleCheckChange(val, data, checked) { - // if (!this.searchData) { - // this.userName = [] - // this.userIds = [] - // if (data.checkedNodes && data.checkedNodes.length > 0) { - // data.checkedNodes.forEach(res => { - // this.userName.push(res.title) - // this.userIds.push(res.id) - // }) - // } - // } - // }, + checkChange(val, checked, indeterminate) { + if (!checked && this.searchData) { + this.userName = this.userName.filter(res => { + return res != val.title + }) + this.userIds = this.userIds.filter(res => { + return res != val.id + }) + for (let i = 0; i < this.userIds.length; i++) { + if (this.userIds[i] == val.parentId) { + this.userIds.splice(i, 1) + this.userName.splice(i, 1) + i-- + } + } + } else if (checked && this.searchData) { + this.userName.push(val.title) + this.userIds.push(val.id) + } + }, + handleCheckChange(val, data, checked) { + if (!this.searchData) { + this.userName = [] + this.userIds = [] + if (data.checkedNodes && data.checkedNodes.length > 0) { + data.checkedNodes.forEach(res => { + this.userName.push(res.title) + this.userIds.push(res.id) + }) + } + } + }, standardClick() { this.treeVisible = false - this.departId = '' + // this.departId = '' this.searchModel = '' this.searchData = '' - this.userIds = [] - this.userName = [] - this.queryDepartUserTreeList(1) + // this.userIds = [] + // this.userName = [] + // this.queryDepartUserTreeList(1) this.visible = true - // let gData = localStorage.getItem('gData') - // if (gData) { - // let dataList = JSON.parse(gData) - // if (!this.selectDepartment) { - // dataList.forEach(res => { - // if (res.type == 'Depart') { - // res.disabled = true - // } - // }) - // } - // this.dataList = this.toTree(dataList) - // } - // setTimeout(() => { - // if (gData) { - // this.gData = this.dataList - // this.gData = [...this.gData] - // // this.treeVisible = true - // if (this.personneQuery[this.query.db_field_name + 'Name']) { - // this.userName = this.personneQuery[this.query.db_field_name + 'Name'].split(',') - // } else if (this.personneQuery[this.query.db_field_name]) { - // this.userName = this.personneQuery[this.query.db_field_name].split(',') - // } else { - // this.userName = [] - // } - // if (this.personneQuery[this.query.db_field_name + '_id']) { - // this.userIds = this.personneQuery[this.query.db_field_name + '_id'].split(',') - // } else if (this.personneQuery[this.query.db_field_name]) { - // this.userIds = this.personneQuery[this.query.db_field_name].split(',') - // } else { - // this.userIds = [] - // } - // this.defaultCheckedKeys = this.userIds - // this.defaultCheckedKeys = [...this.defaultCheckedKeys] - // this.defaultExpandAll = false - // this.treeVisible = true - // } else { - // this.queryDepartUserTreeList(1) - // } - // }, 200) + let gData = localStorage.getItem('gData') + if (gData) { + let dataList = JSON.parse(gData) + if (!this.selectDepartment) { + dataList.forEach(res => { + if (res.type == 'Depart') { + res.disabled = true + } + }) + } + this.dataList = this.toTree(dataList) + } + setTimeout(() => { + if (gData) { + this.gData = this.dataList + this.gData = [...this.gData] + // this.treeVisible = true + if (this.personneQuery[this.query.db_field_name + 'Name']) { + this.userName = this.personneQuery[this.query.db_field_name + 'Name'].split(',') + } else if (this.personneQuery[this.query.db_field_name]) { + this.userName = this.personneQuery[this.query.db_field_name].split(',') + } else { + this.userName = [] + } + if (this.personneQuery[this.query.db_field_name + '_id']) { + this.userIds = this.personneQuery[this.query.db_field_name + '_id'].split(',') + } else if (this.personneQuery[this.query.db_field_name]) { + this.userIds = this.personneQuery[this.query.db_field_name].split(',') + } else { + this.userIds = [] + } + this.defaultCheckedKeys = this.userIds + this.defaultCheckedKeys = [...this.defaultCheckedKeys] + this.defaultExpandAll = false + this.treeVisible = true + } else { + this.queryDepartUserTreeList(1) + } + }, 200) + }, + deleteChildren(value, arr) { + let newarr = [] + arr.forEach(element => { + if (element.title.indexOf(value) > -1) { // 判断条件 + newarr.push(element) + } else { + if (element.children && element.children.length > 0) { + let redata = this.deleteChildren(value, element.children) + if (redata && redata.length > 0) { + let obj = { + ...element, + children: redata + } + newarr.push(obj) + } + } + } + }) + return newarr + }, + // 将数据拼成树形结构 + toTree(config, num) { + // 删除 所有 children,以防止多次调用 + config.forEach(function(item) { + delete item.children + }) + // 将数据存储为 以 id 为 KEY 的 map 索引数据列 + let map = {} + config.forEach((item) => { + item.label = item.name + item.key = item.id + + item.title = item.name + (item.itemName ? ' ' + item.itemName : '') + map[item.id] = item + }) + let val = [] + config.forEach((item) => { + // 以当前遍历项,的pid,去map对象中找到索引的id + let parent = map[item.parentId] + + // 如果找到索引,那么说明此项不在顶级当中,那么需要把此项添加到,他对应的父级中 + if (parent) { + (parent.children || (parent.children = [])).push(item) + } else { + //如果没有在map中找到对应的索引ID,那么直接把 当前的item添加到 val结果集中,作为顶级 + val.push(item) + } + }) + return val }, - // deleteChildren(value, arr) { - // let newarr = [] - // arr.forEach(element => { - // if (element.title.indexOf(value) > -1) { // 判断条件 - // newarr.push(element) - // } else { - // if (element.children && element.children.length > 0) { - // let redata = this.deleteChildren(value, element.children) - // if (redata && redata.length > 0) { - // let obj = { - // ...element, - // children: redata - // } - // newarr.push(obj) - // } - // } - // } - // }) - // return newarr - // }, - //将数据拼成树形结构 - // toTree(config, num) { - // // 删除 所有 children,以防止多次调用 - // config.forEach(function(item) { - // delete item.children - // }) - // // 将数据存储为 以 id 为 KEY 的 map 索引数据列 - // let map = {} - // config.forEach((item) => { - // item.label = item.name - // item.key = item.id - // - // item.title = item.name + (item.itemName ? ' ' + item.itemName : '') - // map[item.id] = item - // }) - // let val = [] - // config.forEach((item) => { - // // 以当前遍历项,的pid,去map对象中找到索引的id - // let parent = map[item.parentId] - // - // // 如果找到索引,那么说明此项不在顶级当中,那么需要把此项添加到,他对应的父级中 - // if (parent) { - // (parent.children || (parent.children = [])).push(item) - // } else { - // //如果没有在map中找到对应的索引ID,那么直接把 当前的item添加到 val结果集中,作为顶级 - // val.push(item) - // } - // }) - // return val - // }, standardDelete() { this.$emit('input', null) this.$forceUpdate() @@ -255,61 +255,61 @@ // this.selectedKey = selectedKeys // }, - onCheck(checkedKeys, info) { - this.userIds = checkedKeys.checked - this.userName = [] - if (this.userIds.length > 0) { - for (let i = 0; i < this.userIds.length; i++) { - for (let j = 0; j < this.defaultCheckedKeysName.length; j++) { - if (this.userIds[i] == this.defaultCheckedKeysName[j].id) { - this.userName.push(this.defaultCheckedKeysName[j].name) - } - } - } - } - if (info.checkedNodes && info.checkedNodes.length > 0) { - info.checkedNodes.forEach(res => { - if (res.data.props.dataRef.key) { - this.content.push({ - id: res.data.props.dataRef.key, - title: res.data.props.dataRef.title - }) - } else { - this.content.push({ - id: res.data.props.id, - title: res.data.props.title - }) - } - }) - } - if (this.content && this.content.length > 0) { - for (let i = 0; i < this.content.length; i++) { - for (let j = i + 1; j < this.content.length; j++) { - if (this.content[i].id == this.content[j].id) { - this.content.splice(j, 1) - j-- - } - } - } - this.userIds.forEach(res => { - this.content.forEach(val => { - if (res == val.id) { - this.userName.push(val.title) - } - }) - }) - } - if (this.userName.length > 0) { - for (let i = 0; i < this.userName.length; i++) { - for (let j = i + 1; j < this.userName.length; j++) { - if (this.userName[i] == this.userName[j]) { - this.userName.splice(j, 1) - j-- - } - } - } - } - }, + // onCheck(checkedKeys, info) { + // this.userIds = checkedKeys.checked + // this.userName = [] + // if (this.userIds.length > 0) { + // for (let i = 0; i < this.userIds.length; i++) { + // for (let j = 0; j < this.defaultCheckedKeysName.length; j++) { + // if (this.userIds[i] == this.defaultCheckedKeysName[j].id) { + // this.userName.push(this.defaultCheckedKeysName[j].name) + // } + // } + // } + // } + // if (info.checkedNodes && info.checkedNodes.length > 0) { + // info.checkedNodes.forEach(res => { + // if (res.data.props.dataRef.key) { + // this.content.push({ + // id: res.data.props.dataRef.key, + // title: res.data.props.dataRef.title + // }) + // } else { + // this.content.push({ + // id: res.data.props.id, + // title: res.data.props.title + // }) + // } + // }) + // } + // if (this.content && this.content.length > 0) { + // for (let i = 0; i < this.content.length; i++) { + // for (let j = i + 1; j < this.content.length; j++) { + // if (this.content[i].id == this.content[j].id) { + // this.content.splice(j, 1) + // j-- + // } + // } + // } + // this.userIds.forEach(res => { + // this.content.forEach(val => { + // if (res == val.id) { + // this.userName.push(val.title) + // } + // }) + // }) + // } + // if (this.userName.length > 0) { + // for (let i = 0; i < this.userName.length; i++) { + // for (let j = i + 1; j < this.userName.length; j++) { + // if (this.userName[i] == this.userName[j]) { + // this.userName.splice(j, 1) + // j-- + // } + // } + // } + // } + // }, handleCancel() { this.visible = false this.treeVisible = false @@ -324,12 +324,16 @@ } let userIds = JSON.parse(JSON.stringify(this.userIds)) let userName = JSON.parse(JSON.stringify(this.userName)) - // userName = userName.filter(function(item, index) { - // return userName.indexOf(item) === index // 因为indexOf 只能查找到第一个 - // }) - // userIds = userIds.filter(function(item, index) { - // return userIds.indexOf(item) === index // 因为indexOf 只能查找到第一个 - // }) + userName = userName.filter(function(item, index) { + return userName.indexOf(item) === index // 因为indexOf 只能查找到第一个 + }) + userIds = userIds.filter(function(item, index) { + return userIds.indexOf(item) === index // 因为indexOf 只能查找到第一个 + }) + if (userIds.length > 100 && this.selectDepartment) { + this.$message.warning(this.$t('OnlyPersonsCanBeSelected')) + return + } this.$emit('input', userName.join(',')) this.$emit('change', this.query.db_field_name, userIds.join(','), this.query.subscript) this.visible = false @@ -347,119 +351,120 @@ this.defaultCheckedKeys = [] }, onSearch(e) { - // this.treeVisible = false - // let p = new Promise((resolve, reject) => { - // resolve() - // }) - // p.then(() => { - // this.searchData = e - // let gData = localStorage.getItem('gData') - // let content = [] - // if (gData) { - // if (e) { - // JSON.parse(gData).forEach(res => { - // if (res.type == 'User') { - // if (res.name.includes(e)) { - // res.color = true - // content.push(res) - // } - // } - // // else if(res.type == 'Depart'){ - // // content.push(res) - // // } - // }) - // let gDataAdmin = this.toTree(content) - // this.gData = this.deleteChildren(e, gDataAdmin) - // this.defaultExpandAll = true - // this.treeVisible = true - // this.defaultCheckedKeys = this.userIds - // this.defaultCheckedKeys = [...this.defaultCheckedKeys] - // this.loading = false - // } else { - // let content = JSON.parse(gData) - // if (!this.selectDepartment) { - // content.forEach(res => { - // if (res.type == 'Depart') { - // res.disabled = true - // } - // }) - // } - // this.gData = this.toTree(content) - // this.defaultExpandAll = false - // this.defaultCheckedKeys = this.userIds - // this.defaultCheckedKeys = [...this.defaultCheckedKeys] - // this.treeVisible = true - // this.loading = false - // } - // } - // }) - this.gData = [] - this.departId = '' - this.visibleTree = false - if (e) { - this.getUserAndDepart() - } else { - this.treeVisible = false - this.queryDepartUserTreeList(2) - } - }, - getUserAndDepart() { - getAction('sys/user/getUserAndDepart', { name: this.searchModel }).then((res) => { - if (res) { - this.gData = res.filter(ele => ele.flag === 'DEPART') - } else { - this.gData = [] - } - this.visibleTree = true + this.treeVisible = false + let p = new Promise((resolve, reject) => { + resolve() }) - }, - onExpand(selectedKeys, val) { - if (this.searchModel == '' || !this.searchModel) { - if (val.expanded) { - if (this.departId == val.node.value) { + p.then(() => { + this.searchData = e + let gData = localStorage.getItem('gData') + let content = [] + if (gData) { + if (e) { + JSON.parse(gData).forEach(res => { + if (res.type == 'User') { + if (res.name.includes(e)) { + res.color = true + content.push(res) + } + } + // else if(res.type == 'Depart'){ + // content.push(res) + // } + }) + let gDataAdmin = this.toTree(content) + this.gData = this.deleteChildren(e, gDataAdmin) + this.defaultExpandAll = true + this.treeVisible = true + this.defaultCheckedKeys = this.userIds + this.defaultCheckedKeys = [...this.defaultCheckedKeys] + this.loading = false } else { - this.departId = val.node.value - this.queryDepartUserTreeList(2) + let content = JSON.parse(gData) + if (!this.selectDepartment) { + content.forEach(res => { + if (res.type == 'Depart') { + res.disabled = true + } + }) + } + this.gData = this.toTree(content) + this.defaultExpandAll = false + this.defaultCheckedKeys = this.userIds + this.defaultCheckedKeys = [...this.defaultCheckedKeys] + this.treeVisible = true + this.loading = false } } - } + }) + // this.gData = [] + // this.departId = '' + // this.visibleTree = false + // if (e) { + // this.getUserAndDepart() + // } else { + // this.treeVisible = false + // this.queryDepartUserTreeList(2) + // } }, + // getUserAndDepart() { + // getAction('sys/user/getUserAndDepart', { name: this.searchModel }).then((res) => { + // if (res) { + // this.gData = res.filter(ele => ele.flag === 'DEPART') + // } else { + // this.gData = [] + // } + // this.visibleTree = true + // }) + // }, + // onExpand(selectedKeys, val) { + // if (this.searchModel == '' || !this.searchModel) { + // if (val.expanded) { + // if (this.departId == val.node.value) { + // } else { + // this.departId = val.node.value + // this.queryDepartUserTreeList(2) + // } + // } + // } + // }, queryDepartUserTreeList(num) { - let gData = JSON.parse(JSON.stringify(this.gData)) - if (gData && gData.length > 0) { - gData = JSON.stringify(gData) - } else { - gData = '' - } + // let gData = JSON.parse(JSON.stringify(this.gData)) + // if (gData && gData.length > 0) { + // gData = JSON.stringify(gData) + // } else { + // gData = '' + // } this.confirmLoading = true this.loading = true - //queryDepartUserTreeList - //queryUserTreeList - postAction('sys/user/queryDepartUserTreeList', { - departId: this.departId, - json: gData, - flag: '1' + //queryDepartUserTreeList post + //queryUserTreeList get + //换接口需要改请求 + getAction('sys/user/queryUserTreeList', { + // departId: this.departId, + // json: gData, + // flag: '1' }).then((res) => { this.confirmLoading = false if (res.success) { this.loading = false // localStorage.setItem('gData', JSON.stringify(res.result)) // this.toTree(dataList) - // let content = JSON.parse(JSON.stringify(res.result)) - // if (!this.selectDepartment) { - // res.result.forEach(res => { - // if (res.type == 'Depart') { - // res.disabled = true - // } - // }) - // } - // localStorage.removeItem('gData') - // localStorage.setItem('gData', JSON.stringify(content)) - // this.gData = this.toTree(res.result) - this.gData = res.result + let content = JSON.parse(JSON.stringify(res.result)) + if (!this.selectDepartment) { + res.result.forEach(res => { + if (res.type == 'Depart') { + res.disabled = true + } + }) + } + localStorage.removeItem('gData') + localStorage.setItem('gData', JSON.stringify(content)) + this.gData = this.toTree(res.result) + // this.gData = res.result this.gData = [...this.gData] // this.gData[0].isLeaf = false - this.defaultExpandedKeys = [this.departId] + // this.defaultExpandedKeys = [this.departId] if (num == 1) { if (this.userName && this.userName.length == 0) { if (this.personneQuery[this.query.db_field_name + 'Name']) { @@ -481,15 +486,15 @@ } this.defaultCheckedKeys = this.userIds this.defaultCheckedKeys = [...this.defaultCheckedKeys] - this.defaultCheckedKeysName = [] - if (this.defaultCheckedKeys.length > 0) { - for (let i = 0; i < this.defaultCheckedKeys.length; i++) { - this.defaultCheckedKeysName.push({ - id: this.defaultCheckedKeys[i], - name: this.userName[i] - }) - } - } + // this.defaultCheckedKeysName = [] + // if (this.defaultCheckedKeys.length > 0) { + // for (let i = 0; i < this.defaultCheckedKeys.length; i++) { + // this.defaultCheckedKeysName.push({ + // id: this.defaultCheckedKeys[i], + // name: this.userName[i] + // }) + // } + // } } this.defaultExpandAll = false this.treeVisible = true From 36d3f0c323a49f560e8d75834481ab06ac2665d9 Mon Sep 17 00:00:00 2001 From: liyawei Date: Mon, 10 Oct 2022 11:45:51 +0800 Subject: [PATCH 026/251] =?UTF-8?q?=E6=96=87=E6=A1=A3=E6=8B=86=E5=88=86-?= =?UTF-8?q?=E8=A7=A3=E5=86=B3=E4=B8=80=E6=AC=A1=E6=89=B9=E9=87=8F=E6=8F=92?= =?UTF-8?q?=E5=85=A5=E5=A4=AA=E5=A4=9APacketTooBigException=E5=BC=82?= =?UTF-8?q?=E5=B8=B8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../impl/FileSplitItemsEOServiceImpl.java | 21 ++++++++++++++++- .../service/impl/FileSplitPdfService.java | 2 +- .../SarFileSplitItemsValEOServiceImpl.java | 23 +++++++++++++++++-- 3 files changed, 42 insertions(+), 4 deletions(-) diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/split/service/impl/FileSplitItemsEOServiceImpl.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/split/service/impl/FileSplitItemsEOServiceImpl.java index de51fcadf..c4c4dd28f 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/split/service/impl/FileSplitItemsEOServiceImpl.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/split/service/impl/FileSplitItemsEOServiceImpl.java @@ -3754,7 +3754,26 @@ public class FileSplitItemsEOServiceImpl extends ServiceImpl messageList) { - return dao.insertForeach(messageList); + // 解决一次批量插入太多 PacketTooBigException 异常 + int total = messageList.size(); + int count = 0; + int pageSum = 1; + if(total > 100) { + pageSum = total / 100; // 总页数 + if ((total % 100) > 0) { + pageSum += 1; + } + } + List subList = new ArrayList<>(); + for(int i = 0; i < pageSum; i++) { + int j = i*100+100; + if (i == pageSum -1) { + j = total; + } + subList = messageList.subList(i*100, j); + count += dao.insertForeach(subList); + } + return count; } /** diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/split/service/impl/FileSplitPdfService.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/split/service/impl/FileSplitPdfService.java index 1946515db..79ddc5648 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/split/service/impl/FileSplitPdfService.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/split/service/impl/FileSplitPdfService.java @@ -1784,7 +1784,7 @@ public class FileSplitPdfService { if(StringUtils.isNotBlank(preName)) { List nowStartList = fileSpiltService.getNewNowStart(preName); - List subList1 = startDigitList.subList(preNameNum, startDigitList.size()-1); + List subList1 = startDigitList.subList(preNameNum, startDigitList.size()); // 后文有一级以下的标题 for (int i = nowStartList.size() - 1; i >= 1; i--) { int index1 = subList1.indexOf(nowStartList.get(i)); diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/split/service/impl/SarFileSplitItemsValEOServiceImpl.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/split/service/impl/SarFileSplitItemsValEOServiceImpl.java index 87e8331e3..1ab1404f2 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/split/service/impl/SarFileSplitItemsValEOServiceImpl.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/split/service/impl/SarFileSplitItemsValEOServiceImpl.java @@ -12,6 +12,7 @@ import org.springframework.stereotype.Service; import org.springframework.transaction.annotation.Propagation; import org.springframework.transaction.annotation.Transactional; +import java.util.ArrayList; import java.util.List; @@ -79,8 +80,26 @@ public class SarFileSplitItemsValEOServiceImpl extends ServiceImpl itemValList) { - - return dao.insertForeach(itemValList); + // 解决一次批量插入太多 PacketTooBigException 异常 + int total = itemValList.size(); + int count = 0; + int pageSum = 1; + if(total > 100) { + pageSum = total / 100; // 总页数 + if ((total % 100) > 0) { + pageSum += 1; + } + } + List subList = new ArrayList<>(); + for(int i = 0; i < pageSum; i++) { + int j = i*100+100; + if (i == pageSum -1) { + j = total; + } + subList = itemValList.subList(i*100, j); + count += dao.insertForeach(subList); + } + return count; } } From cc3554958aaac5dc29c5a1f0b3ae6e46f08e2d66 Mon Sep 17 00:00:00 2001 From: sunFlower <787203167@qq.com> Date: Mon, 10 Oct 2022 13:46:57 +0800 Subject: [PATCH 027/251] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E7=A6=85=E9=81=93?= =?UTF-8?q?=E5=B7=B2=E7=9F=A5bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- jero-web/src/components/virtualNodeTree/tree.vue | 5 ++--- .../components/problemKnowledgeBaseList.vue | 4 ++-- .../components/problemKnowledgeBaseListView.vue | 10 ++++++---- 3 files changed, 10 insertions(+), 9 deletions(-) diff --git a/jero-web/src/components/virtualNodeTree/tree.vue b/jero-web/src/components/virtualNodeTree/tree.vue index a98fea522..9d58be060 100644 --- a/jero-web/src/components/virtualNodeTree/tree.vue +++ b/jero-web/src/components/virtualNodeTree/tree.vue @@ -759,8 +759,8 @@ } .el-checkbox__input.is-disabled.is-indeterminate .el-checkbox__inner:before { - background-color: #c0c4cc; - border-color: #c0c4cc + background-color: #fff; + border-color: #fff; } .el-checkbox__input.is-checked .el-checkbox__inner, .el-checkbox__input.is-indeterminate .el-checkbox__inner { @@ -927,7 +927,6 @@ .el-checkbox-button.is-checked:first-child .el-checkbox-button__inner { border-left-color: #409eff } - .el-checkbox-button.is-disabled .el-checkbox-button__inner { color: #c0c4cc; cursor: not-allowed; diff --git a/jero-web/src/views/businessSupport/problemKnowledgeBase/components/problemKnowledgeBaseList.vue b/jero-web/src/views/businessSupport/problemKnowledgeBase/components/problemKnowledgeBaseList.vue index a73a4a075..1c1ef45bd 100644 --- a/jero-web/src/views/businessSupport/problemKnowledgeBase/components/problemKnowledgeBaseList.vue +++ b/jero-web/src/views/businessSupport/problemKnowledgeBase/components/problemKnowledgeBaseList.vue @@ -662,12 +662,12 @@ margin-top: 10px; .content-box-content-botton-text { - width: 118px; + max-width: 198px; height: 32px; display: inline-block; text-align: center; line-height: 32px; - padding: 0 6px; + padding: 0 10px; background: #EFF1F3; border-radius: 4px; text-overflow: ellipsis; diff --git a/jero-web/src/views/businessSupport/problemKnowledgeBase/components/problemKnowledgeBaseListView.vue b/jero-web/src/views/businessSupport/problemKnowledgeBase/components/problemKnowledgeBaseListView.vue index 6a4253db1..78ad86e43 100644 --- a/jero-web/src/views/businessSupport/problemKnowledgeBase/components/problemKnowledgeBaseListView.vue +++ b/jero-web/src/views/businessSupport/problemKnowledgeBase/components/problemKnowledgeBaseListView.vue @@ -222,7 +222,7 @@ } else if (fileSuffix == '.xlsx' || fileSuffix == '.xls') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + fileQuery.id + fileSuffix) window.open(url, '_blank') - }else if(fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg'){ + } else if (fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadImgUrl + '/' + fileQuery.id + fileSuffix) window.open(url, '_blank') } else { @@ -494,12 +494,13 @@ margin-top: 10px; .content-box-content-botton-text { - width: 140px; + max-width: 200px; + /*min-width: 120px;*/ height: 32px; display: inline-block; text-align: center; line-height: 32px; - padding: 0 6px; + padding: 0 10px; background: #EFF1F3; border-radius: 4px; text-overflow: ellipsis; @@ -512,7 +513,7 @@ cursor: pointer; .file-text { - width: 90px; + width: calc(100% - 30px); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; @@ -522,6 +523,7 @@ } .icon-text { + width: 24px; font-size: 16px; overflow: hidden; margin-bottom: 9px; From 0ba8ed9a274f2105e1565a28d1b977a68baa14b7 Mon Sep 17 00:00:00 2001 From: sunFlower <787203167@qq.com> Date: Mon, 10 Oct 2022 14:41:42 +0800 Subject: [PATCH 028/251] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E7=A6=85=E9=81=93?= =?UTF-8?q?=E5=B7=B2=E7=9F=A5bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- jero-web/src/components/setCreator/index.vue | 392 ++++++++++++++----- 1 file changed, 292 insertions(+), 100 deletions(-) diff --git a/jero-web/src/components/setCreator/index.vue b/jero-web/src/components/setCreator/index.vue index 12c38aa43..4d5537bb3 100644 --- a/jero-web/src/components/setCreator/index.vue +++ b/jero-web/src/components/setCreator/index.vue @@ -15,18 +15,38 @@ allowClear :placeholder="$t('NodeQuickLookup')"/>
- - + + + + {{ data.title }} + + + + + + + + + + + + + + +
@@ -40,15 +60,20 @@ @@ -243,4 +428,11 @@ height: calc(100% - 60px); overflow: auto; } + .treeWrap { + height: calc(100vh - 240px); + } + .active { + color: #21c9cc; + display: inline-block; + } From 2a8f87a69741d372915107b28654f1a9c3172e95 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=AB=98=E5=B5=A9?= Date: Mon, 10 Oct 2022 15:01:18 +0800 Subject: [PATCH 029/251] =?UTF-8?q?=E6=96=87=E6=A1=A3=E5=AF=B9=E6=AF=94-?= =?UTF-8?q?=E4=BF=AE=E6=94=B9=E5=AF=B9=E6=AF=94=E7=BB=93=E6=9E=9C=E6=96=87?= =?UTF-8?q?=E4=BB=B6=E9=A2=84=E8=A7=88?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../compare/entity/SarFileCompareResultVO.java | 18 ++++++++++++++++++ .../SarFileCompareItemCommentServiceImpl.java | 2 ++ 2 files changed, 20 insertions(+) diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/entity/SarFileCompareResultVO.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/entity/SarFileCompareResultVO.java index 9236eebf8..c517ef2bc 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/entity/SarFileCompareResultVO.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/entity/SarFileCompareResultVO.java @@ -8,8 +8,10 @@ public class SarFileCompareResultVO { private String infoId; private String serialNumberLeft; private String fileNameLeft; + private String fileIdLeft; private String serialNumberRight; private String fileNameRight; + private String fileIdRight; private List resList; private String comments; @@ -78,4 +80,20 @@ public class SarFileCompareResultVO { public void setComments(String comments) { this.comments = comments; } + + public String getFileIdLeft() { + return fileIdLeft; + } + + public void setFileIdLeft(String fileIdLeft) { + this.fileIdLeft = fileIdLeft; + } + + public String getFileIdRight() { + return fileIdRight; + } + + public void setFileIdRight(String fileIdRight) { + this.fileIdRight = fileIdRight; + } } diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/service/impl/SarFileCompareItemCommentServiceImpl.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/service/impl/SarFileCompareItemCommentServiceImpl.java index 071f02deb..965435538 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/service/impl/SarFileCompareItemCommentServiceImpl.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/service/impl/SarFileCompareItemCommentServiceImpl.java @@ -142,8 +142,10 @@ public class SarFileCompareItemCommentServiceImpl extends ServiceImpl list = queryListByInfoId(infoId,comment); From b19922daee7977c06eb7909defba50a447823bb9 Mon Sep 17 00:00:00 2001 From: CD <1103614279@qq.com> Date: Mon, 10 Oct 2022 15:08:04 +0800 Subject: [PATCH 030/251] =?UTF-8?q?=E5=AF=B9=E5=A4=96=E6=8A=A5=E5=91=8A=20?= =?UTF-8?q?=E4=B8=8A=E4=BC=A0=E6=8C=89=E9=92=AE=E4=BB=A5=E5=8F=8A=E6=96=87?= =?UTF-8?q?=E4=BB=B6=E5=AF=B9=E5=BA=94=E6=93=8D=E4=BD=9C=E6=8C=89=E9=92=AE?= =?UTF-8?q?=E7=9A=84=E6=98=BE=E7=A4=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../modules/extRepo/controller/ExtRepoDataController.java | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/extRepo/controller/ExtRepoDataController.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/extRepo/controller/ExtRepoDataController.java index 4c6513783..5215dc1ab 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/extRepo/controller/ExtRepoDataController.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/extRepo/controller/ExtRepoDataController.java @@ -25,6 +25,7 @@ import org.springframework.web.servlet.ModelAndView; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; +import javax.servlet.http.HttpSession; import java.text.SimpleDateFormat; import java.util.Arrays; import java.util.Date; @@ -92,7 +93,11 @@ public class ExtRepoDataController extends JeroController pageList = extRepoDataService.page(page, queryWrapper); - ExtRepoDataPage res = new ExtRepoDataPage(extRepoFolderService.haveManageAuth(extRepoData.getSupFolder()), pageList); + //判断当前文件夹或者上级文件夹是否有权限 + HttpSession session = req.getSession(); + session.setAttribute("haveSuperiorManageAuth", false); + extRepoFolderService.haveSuperiorManageAuth(extRepoData.getSupFolder(),session); + ExtRepoDataPage res = new ExtRepoDataPage((Boolean)session.getAttribute("haveSuperiorManageAuth"), pageList); return Result.OK(res); } From 49c1ea3648ae4b97657e1ae4bd4f65bc2c987d47 Mon Sep 17 00:00:00 2001 From: CD <1103614279@qq.com> Date: Mon, 10 Oct 2022 15:24:21 +0800 Subject: [PATCH 031/251] =?UTF-8?q?=E5=B7=AE=E5=BC=82=E8=AF=84=E4=BC=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../compare/enums/AssessConsistencyEnum.java | 21 +++++++++++++++++++ .../SarFileCompareItemCommentServiceImpl.java | 13 ++++++++++-- 2 files changed, 32 insertions(+), 2 deletions(-) create mode 100644 jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/enums/AssessConsistencyEnum.java diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/enums/AssessConsistencyEnum.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/enums/AssessConsistencyEnum.java new file mode 100644 index 000000000..8e5eeeab6 --- /dev/null +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/enums/AssessConsistencyEnum.java @@ -0,0 +1,21 @@ +package com.jero.modules.compare.enums; + +public enum AssessConsistencyEnum { + + SAME("一致"), + DIFFERENT("差异"); + + private String value; + + public String getValue() { + return value; + } + + public void setValue(String value) { + this.value = value; + } + + AssessConsistencyEnum(String value) { + this.value = value; + } +} diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/service/impl/SarFileCompareItemCommentServiceImpl.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/service/impl/SarFileCompareItemCommentServiceImpl.java index f0e09dab7..c833e10cd 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/service/impl/SarFileCompareItemCommentServiceImpl.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/compare/service/impl/SarFileCompareItemCommentServiceImpl.java @@ -7,6 +7,7 @@ import com.jero.common.constant.enums.CutEnum; import com.jero.common.exception.JeroBootException; import com.jero.common.util.oss.CosBootUtil; import com.jero.modules.compare.entity.*; +import com.jero.modules.compare.enums.AssessConsistencyEnum; import com.jero.modules.compare.mapper.SarFileCompareItemCommentMapper; import com.jero.modules.compare.service.ISarFileCompareInfoService; import com.jero.modules.compare.service.ISarFileCompareItemCommentService; @@ -182,7 +183,11 @@ public class SarFileCompareItemCommentServiceImpl extends ServiceImpl queryListByInfoId(String infoId,String comment) { LambdaQueryWrapper queryWrapper = new LambdaQueryWrapper<>(); if (ObjectUtils.isNotEmpty(comment)) { - queryWrapper.eq(SarFileCompareItemComment::getComment, comment); + if (AssessConsistencyEnum.SAME.getValue().equals(comment)) { + queryWrapper.eq(SarFileCompareItemComment::getComment, comment); + } else if (AssessConsistencyEnum.DIFFERENT.getValue().equals(comment)) { + queryWrapper.ne(SarFileCompareItemComment::getComment, AssessConsistencyEnum.SAME.getValue()); + } } queryWrapper.eq(SarFileCompareItemComment::getInfoId, infoId); queryWrapper.orderBy(true, true, SarFileCompareItemComment::getCreateTime); @@ -203,7 +208,11 @@ public class SarFileCompareItemCommentServiceImpl extends ServiceImpl Date: Mon, 10 Oct 2022 15:47:33 +0800 Subject: [PATCH 032/251] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E7=A6=85=E9=81=93?= =?UTF-8?q?=E5=B7=B2=E7=9F=A5bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- jero-web/src/common/lang/en-us.js | 5 +- jero-web/src/common/lang/zh-cn.js | 5 +- .../collectionOfRegulatoryOpinions/index.vue | 8 +- .../technologyAssessment/index.vue | 15 ++- .../components/comparisonResults.vue | 120 +++++++++++++++--- 5 files changed, 125 insertions(+), 28 deletions(-) diff --git a/jero-web/src/common/lang/en-us.js b/jero-web/src/common/lang/en-us.js index cb6a0ad64..641254c9d 100644 --- a/jero-web/src/common/lang/en-us.js +++ b/jero-web/src/common/lang/en-us.js @@ -1312,8 +1312,9 @@ module.exports = { firstLevelDirectory:'First level directory', deselectAll:'Deselect All', classification:'Classification', - consistentAssessment:'Consistent assessment', - viewConsistentAssessment:'View Consistent Assessment', + consistentAssessment:'Consistent', + viewConsistentAssessment:'View Consistent', + viewVarianceAssessment:'View Variance', viewAll:'View All', endProcess:'End Process', thereForTheCurrentlySelectedData:'There is no standard breakdown for the currently selected data', diff --git a/jero-web/src/common/lang/zh-cn.js b/jero-web/src/common/lang/zh-cn.js index 28ce6b3c9..5dcd838f0 100644 --- a/jero-web/src/common/lang/zh-cn.js +++ b/jero-web/src/common/lang/zh-cn.js @@ -1413,8 +1413,9 @@ module.exports = { firstLevelDirectory:'一级目录', deselectAll:'取消全选', classification:'分类', - consistentAssessment:'一致评估', - viewConsistentAssessment:'查看一致评估', + consistentAssessment:'一致', + viewConsistentAssessment:'查看一致项', + viewVarianceAssessment:'查看差异项', viewAll:'查看全部', endProcess:'结束流程', thereForTheCurrentlySelectedData:'当前所选数据暂无标准分解单', diff --git a/jero-web/src/views/businessSupport/collectionOfRegulatoryOpinions/index.vue b/jero-web/src/views/businessSupport/collectionOfRegulatoryOpinions/index.vue index 5ea7211b3..4f9789fa2 100644 --- a/jero-web/src/views/businessSupport/collectionOfRegulatoryOpinions/index.vue +++ b/jero-web/src/views/businessSupport/collectionOfRegulatoryOpinions/index.vue @@ -41,10 +41,10 @@
-
{{$t('classificationMaintenance')}} @@ -42,11 +44,15 @@ -
+
{{$t('managePublishing')}}
-
+
{{$t('newlyAdded')}}
diff --git a/jero-web/src/views/businessSupport/regulationReport/components/RegulationMonthlyFill.vue b/jero-web/src/views/businessSupport/regulationReport/components/RegulationMonthlyFill.vue index 0fa66b3aa..2be197f75 100644 --- a/jero-web/src/views/businessSupport/regulationReport/components/RegulationMonthlyFill.vue +++ b/jero-web/src/views/businessSupport/regulationReport/components/RegulationMonthlyFill.vue @@ -44,19 +44,27 @@
-
+
{{$t('monthlyTitleTemplate')}}
-
+
{{$t('monthlyIntegrationAndExport')}}
-
+
{{$t('addContent')}}
-
+
{{$t('BatchDelete')}}
@@ -74,10 +82,28 @@ :columns="columns" > - {{$t('copy')}} - {{$t('view')}} - {{$t('edit')}} - {{$t('deleteLib')}} + + {{$t('copy')}} + + + {{$t('view')}} + + + {{$t('edit')}} + + + {{$t('deleteLib')}} +
@@ -103,6 +129,7 @@ import fillTable from './modules/fillTable' import fillAdd from './modules/fillAdd' import moment from 'moment' + import { mapGetters } from 'vuex' export default { name: 'RegulationMonthlyFill', @@ -118,14 +145,14 @@ list: '/report/lawsMonthlyReportWriteEO/page', exportData: '/report/lawsMonthlyReportWriteEO/exportMonthlyReport' }, - exportStatusList:[ + exportStatusList: [ { - value:'2', - name:this.$t('hasBeenExport') + value: '2', + name: this.$t('hasBeenExport') }, { - value:'1', - name:this.$t('notExport') + value: '1', + name: this.$t('notExport') } ], loading: false, @@ -192,15 +219,27 @@ width: 190, scopedSlots: { customRender: 'operation' } } - ] + ], + userData:{}, + administrators:false } }, mounted() { this.queryParam.month = moment(new Date()).format('YYYY-MM') this.getList() + this.userData = this.userInfo() + this.administrators = false + if (this.userInfo().userRoleList && this.userInfo().userRoleList.length > 0) { + this.userInfo().userRoleList.forEach(res => { + if (res.roleCode == 'admin') { + this.administrators = true + } + }) + } }, methods: { - copyClick(row){ + ...mapGetters(['userInfo']), + copyClick(row) { let _this = this this.$confirm({ content: _this.$t('ConfirmReplication'), diff --git a/jero-web/src/views/businessSupport/regulationReport/components/RegulationMonthlyManagement.vue b/jero-web/src/views/businessSupport/regulationReport/components/RegulationMonthlyManagement.vue index 09ff3b0f0..a89cbe2cd 100644 --- a/jero-web/src/views/businessSupport/regulationReport/components/RegulationMonthlyManagement.vue +++ b/jero-web/src/views/businessSupport/regulationReport/components/RegulationMonthlyManagement.vue @@ -22,7 +22,7 @@
-
+
{{$t('uploadMonthly')}}
@@ -51,14 +51,16 @@ {{record.issueStatus == 2 ? $t('release') : $t('withdraw')}} {{$t('deleteLib')}} {{$t('download')}} @@ -110,6 +112,7 @@ downLoadFileUrl: window._CONFIG['domianPreviewURL'] + '/sys/common/download', downLoadImgUrl: window._CONFIG['domianWebImgURL'] + '/sys/common/download', userData: {}, + administrators:false, columns: [ { title: this.$t('RegulationMonthlyName'), @@ -161,6 +164,14 @@ mounted() { this.getList() this.userData = this.userInfo() + this.administrators = false + if (this.userInfo().userRoleList && this.userInfo().userRoleList.length > 0) { + this.userInfo().userRoleList.forEach(res => { + if (res.roleCode == 'admin') { + this.administrators = true + } + }) + } }, methods: { ...mapGetters(['userInfo']), From 1bc76b06c9b1280e5f112ae33b8a055168c1f6c2 Mon Sep 17 00:00:00 2001 From: sunFlower <787203167@qq.com> Date: Thu, 13 Oct 2022 15:01:29 +0800 Subject: [PATCH 063/251] =?UTF-8?q?=E6=8C=89=E9=92=AE=E6=9D=83=E9=99=90?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- jero-web/src/views/externalReports/index.vue | 2115 +++++++++-------- .../src/views/regulationsKanban/index.vue | 6 +- 2 files changed, 1071 insertions(+), 1050 deletions(-) diff --git a/jero-web/src/views/externalReports/index.vue b/jero-web/src/views/externalReports/index.vue index f10dccbfc..0543db04a 100644 --- a/jero-web/src/views/externalReports/index.vue +++ b/jero-web/src/views/externalReports/index.vue @@ -41,11 +41,11 @@ {{title && title.length > 18?title.slice(0,17)+'...':title}} @@ -82,16 +82,17 @@
{{ $t('uploadTime') }}
- + + class="box-input" + @change="onChange" + style='margin-left: -1px' + v-model="queryParams.time" + :disabled="false"/>
- + @@ -106,18 +107,22 @@
-
+
{{ $t('UploadFile') }}
-
+
{{ $t('BatchDelete') }}
@@ -158,9 +169,9 @@ />
- + - + - -
-
- * - {{$t('Foldername')}} + +
+
+ * + {{$t('Foldername')}} +
+ + +
- - - -
- - + +
@@ -245,10 +256,10 @@ {{$t('Folderorder')}}
- + + :parser="limitNumber"/>
@@ -257,453 +268,453 @@
-
+
-
+
+ + + .split-detail-search-header { + .ant-col-sm-8 { + min-width: 300px; + } - \ No newline at end of file diff --git a/jero-web/src/views/regulationsKanban/index.vue b/jero-web/src/views/regulationsKanban/index.vue index 4dd1c1f39..6ec89741c 100644 --- a/jero-web/src/views/regulationsKanban/index.vue +++ b/jero-web/src/views/regulationsKanban/index.vue @@ -65,7 +65,9 @@
-
+
{{ $t('Deriveconformanceresults') }}
@@ -96,7 +98,7 @@ - {{$t('view')}} + {{$t('view')}}
From 0fc0cb29abc66472e9141b421de522f9cd6ca786 Mon Sep 17 00:00:00 2001 From: zhn <947514737@qq.com> Date: Thu, 13 Oct 2022 15:52:26 +0800 Subject: [PATCH 064/251] =?UTF-8?q?=E6=9C=88=E6=8A=A5=E5=AF=BC=E5=87=BA--?= =?UTF-8?q?=E9=BB=98=E8=AE=A4=E6=A8=A1=E6=9D=BF=E5=8E=BB=E6=8E=89=E5=AE=9E?= =?UTF-8?q?=E6=96=BD=E8=BD=A6=E5=9E=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../jero/modules/report/util/WordUtil.java | 32 +++++++++---------- 1 file changed, 16 insertions(+), 16 deletions(-) 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 0f2595d22..048c0ee08 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 @@ -454,7 +454,7 @@ public class WordUtil { String applyScope = lawsMonthlyReportWriteEO.getApplyScope();//适用范围 String state = lawsMonthlyReportWriteEO.getState();//状态 String useMethod = lawsMonthlyReportWriteEO.getUseMethod();//用法 - String implementCar = lawsMonthlyReportWriteEO.getImplementCar();//实施车型 +// String implementCar = lawsMonthlyReportWriteEO.getImplementCar();//实施车型 String newCarImplementTime = lawsMonthlyReportWriteEO.getNewCarImplementTime();//新车型实施日期 String productionCarImplementTime = lawsMonthlyReportWriteEO.getProductionCarImplementTime();//在产车实施日期 String contentCn = lawsMonthlyReportWriteEO.getContentCn();//主要内容中文 @@ -504,7 +504,7 @@ public class WordUtil { String stateName = dictItem(sysDictItems, state,cut, DictCodeReportEnum.STATE.getValue()); String useMethodName = dictItem(sysDictItems, useMethod,cut, DictCodeReportEnum.USEMETHOD.getValue()); - XWPFTable table = document.createTable(11, 2); + XWPFTable table = document.createTable(10, 2); //表格属性 CTTblPr tablePr = table.getCTTbl().addNewTblPr(); //固定列宽(英文和数字的时候自动换行) @@ -534,19 +534,19 @@ public class WordUtil { //第5行 setCellThree(table,3, "用法",useMethodName,sysDictItems,DictCodeReportEnum.USEMETHOD.getValue()); //第6行 - setCell(table,4, "实施车型",implementCar); +// setCell(table,4, "实施车型",implementCar); //第7行 - setCell(table,5, "新车型实施日期",newCarImplementTime); + setCell(table,4, "新车型实施日期",newCarImplementTime); //第8行 - setCell(table,6, "在产车实施日期",productionCarImplementTime); + setCell(table,5, "在产车实施日期",productionCarImplementTime); //第9行 - setCell(table,7, "主要内容",contentCn); + setCell(table,6, "主要内容",contentCn); //第10行 - setCell(table,8, "NIO工作进展",workProgressCn); + setCell(table,7, "NIO工作进展",workProgressCn); //第11行 - setCell(table,9, "法规联系人",lawsContact); + setCell(table,8, "法规联系人",lawsContact); //第12行 - setCell(table,10, "链接",link); + setCell(table,9, "链接",link); }else{ //第1行 setCell(table,0, "Related Areas",technologyTerritoryName); @@ -559,19 +559,19 @@ public class WordUtil { //第5行 setCellThree(table,3,"Usage",useMethodName,sysDictItems,DictCodeReportEnum.APPLYSCOPE.getValue()); //第6行 - setCell(table,4,"Implementation Model",implementCar); +// setCell(table,4,"Implementation Model",implementCar); //第7行 - setCell(table,5,"New Type Execution Date",newCarImplementTime); + setCell(table,4,"New Type Execution Date",newCarImplementTime); //第8行 - setCell(table,6,"New Vehicle Execution Date",productionCarImplementTime); + setCell(table,5,"New Vehicle Execution Date",productionCarImplementTime); //第9行 - setCell(table,7,"Main Content",contentEn); + setCell(table,6,"Main Content",contentEn); //第10行 - setCell(table,8,"NIO Work Progress",workProgressEn); + setCell(table,7,"NIO Work Progress",workProgressEn); //第11行 - setCell(table,9,"Regulatory Contact",lawsContact); + setCell(table,8,"Regulatory Contact",lawsContact); //第12行 - setCell(table, 10,"Link",link); + setCell(table, 9,"Link",link); } // ctTblLayoutType.setType(STTblLayoutType.FIXED); From 232b8efa286071a0373665950e95bad39ec79470 Mon Sep 17 00:00:00 2001 From: wangzhijiang <12345678> Date: Thu, 13 Oct 2022 16:20:38 +0800 Subject: [PATCH 065/251] =?UTF-8?q?=E6=B3=95=E8=A7=84=E6=8A=80=E6=9C=AF?= =?UTF-8?q?=E8=AF=84=E4=BC=B0=E3=80=81=E6=B3=95=E8=A7=84=E6=84=8F=E8=A7=81?= =?UTF-8?q?=E6=94=B6=E9=9B=86-=E5=A2=9E=E5=8A=A0=E6=95=B0=E6=8D=AE?= =?UTF-8?q?=E6=9D=83=E9=99=90=E3=80=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../LawsOpinionGatherEOController.java | 18 +++++++++++ .../entity/LawsOpinionGatherEO.java | 4 +++ .../impl/LawsOpinionGatherEOServiceImpl.java | 8 +++++ .../LawsTechnologyEvaluationEOController.java | 15 ++++++++++ .../entity/LawsTechnologyEvaluationEO.java | 3 ++ .../ILawsTechnologyEvaluationEOService.java | 3 ++ ...LawsTechnologyEvaluationEOServiceImpl.java | 30 +++++++++++++++++++ 7 files changed, 81 insertions(+) diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/lawsOpinionGather/controller/LawsOpinionGatherEOController.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/lawsOpinionGather/controller/LawsOpinionGatherEOController.java index 6eec32d23..69864ff66 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/lawsOpinionGather/controller/LawsOpinionGatherEOController.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/lawsOpinionGather/controller/LawsOpinionGatherEOController.java @@ -8,13 +8,16 @@ import javax.servlet.http.HttpServletResponse; import com.alibaba.fastjson.JSONObject; import com.jero.common.api.vo.Result; import com.jero.common.system.query.QueryGenerator; +import com.jero.common.system.vo.LoginUser; import com.jero.modules.lawsOpinionGather.entity.LawsOpinionGatherEO; import com.jero.modules.lawsOpinionGather.service.ILawsOpinionGatherEOService; import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; import com.baomidou.mybatisplus.core.metadata.IPage; import com.baomidou.mybatisplus.extension.plugins.pagination.Page; +import com.jero.modules.system.service.ISysUserService; import lombok.extern.slf4j.Slf4j; import com.jero.common.system.base.controller.JeroController; +import org.apache.shiro.SecurityUtils; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.validation.annotation.Validated; import org.springframework.web.bind.annotation.*; @@ -37,6 +40,8 @@ import com.jero.common.aspect.annotation.AutoLog; public class LawsOpinionGatherEOController extends JeroController { @Autowired private ILawsOpinionGatherEOService lawsOpinionGatherEOService; + @Autowired + private ISysUserService sysUserService; /** * 分页列表查询 @@ -57,6 +62,19 @@ public class LawsOpinionGatherEOController extends JeroController queryWrapper = QueryGenerator.initQueryWrapper(lawsOpinionGatherEO, req.getParameterMap()); queryWrapper.orderByDesc("start_time"); + /** + * 创建查询数据权限,超级管理员可以看到所有的数据,并且能删除,其它用户只能看到自己创建、或自己为评估人的数据。 + */ + boolean administrator = this.sysUserService.isAdministrator(); + if(!administrator){ + LoginUser currentUser = (LoginUser) SecurityUtils.getSubject().getPrincipal(); + //如果不是超级管理员,获取自己所有参与过的法规意见收集 + queryWrapper.and(query -> { + query.eq("create_by",currentUser.getUsername()); + query.or().like("evaluator_ids",currentUser.getId()); + }); + } + Page page = new Page(pageNo, pageSize); IPage pageList = lawsOpinionGatherEOService.page(page, queryWrapper); this.lawsOpinionGatherEOService.disposeData(pageList.getRecords(),cut); diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/lawsOpinionGather/entity/LawsOpinionGatherEO.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/lawsOpinionGather/entity/LawsOpinionGatherEO.java index 78205d522..91adffa7a 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/lawsOpinionGather/entity/LawsOpinionGatherEO.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/lawsOpinionGather/entity/LawsOpinionGatherEO.java @@ -122,4 +122,8 @@ public class LawsOpinionGatherEO implements Serializable { @ApiModelProperty(value = "评估人ids,多个之间使用英文逗号分隔") private String evaluatorIds; + + /**删除标识 true 可以删除,false,没有权限删除**/ + @TableField(exist = false) + private boolean deleteFlag = false; } diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/lawsOpinionGather/service/impl/LawsOpinionGatherEOServiceImpl.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/lawsOpinionGather/service/impl/LawsOpinionGatherEOServiceImpl.java index 376cc56a3..60217e805 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/lawsOpinionGather/service/impl/LawsOpinionGatherEOServiceImpl.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/lawsOpinionGather/service/impl/LawsOpinionGatherEOServiceImpl.java @@ -6,6 +6,7 @@ import com.jero.common.api.vo.Result; import com.jero.common.constant.enums.CutEnum; import com.jero.common.constant.enums.MessageTypeEnum; import com.jero.common.exception.JeroBootException; +import com.jero.common.system.vo.LoginUser; import com.jero.modules.feishu.vo.FeishuMsgVo; import com.jero.modules.lawsOpinionGather.entity.LawsOpinionGatherEO; import com.jero.modules.lawsOpinionGather.enums.GatherResultEnum; @@ -31,6 +32,7 @@ import com.jero.modules.system.service.impl.SysCategoryServiceImpl; import com.jero.modules.wkflow.feginClient.WorkFlowFeignClient; import org.apache.commons.collections4.CollectionUtils; import org.apache.commons.lang3.StringUtils; +import org.apache.shiro.SecurityUtils; import org.jeecg.modules.jmreport.common.constant.CommonConstant; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Value; @@ -197,6 +199,8 @@ public class LawsOpinionGatherEOServiceImpl extends ServiceImpl lawsOpinionGatherEOList,String cut) { if(CollectionUtils.isNotEmpty(lawsOpinionGatherEOList)){ + boolean administrator = this.sysUserService.isAdministrator(); + LoginUser currentUser = (LoginUser) SecurityUtils.getSubject().getPrincipal(); //树形数据字典 List technologyTerritoryList = sysCategoryService.list(); lawsOpinionGatherEOList.forEach(lawsOpinionGather -> { @@ -211,6 +215,10 @@ public class LawsOpinionGatherEOServiceImpl extends ServiceImpl opinionArchiveFileList = iOSSFileService.getFileInfosByConnectId(StringUtils.join(lawsOpinionGather.getOpinionArchiveId(), ",")); lawsOpinionGather.setOpinionArchiveFileList(opinionArchiveFileList); } + //如果当前用户是超级管理员,或是这条数据的创建人,给删除权限。 + if(StringUtils.equals(lawsOpinionGather.getCreateBy(),currentUser.getUsername()) || administrator){ + lawsOpinionGather.setDeleteFlag(true); + } }); } } diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/lawsTechnologyEvaluation/controller/LawsTechnologyEvaluationEOController.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/lawsTechnologyEvaluation/controller/LawsTechnologyEvaluationEOController.java index ca025a19e..eb3ec59fd 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/lawsTechnologyEvaluation/controller/LawsTechnologyEvaluationEOController.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/lawsTechnologyEvaluation/controller/LawsTechnologyEvaluationEOController.java @@ -3,19 +3,26 @@ package com.jero.modules.lawsTechnologyEvaluation.controller; import java.util.Arrays; import java.util.List; import java.util.Map; +import java.util.stream.Collectors; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; import com.alibaba.fastjson.JSONObject; import com.jero.common.api.vo.Result; import com.jero.common.system.query.QueryGenerator; +import com.jero.common.system.vo.LoginUser; import com.jero.modules.lawsTechnologyEvaluation.entity.LawsTechnologyEvaluationEO; +import com.jero.modules.lawsTechnologyEvaluation.entity.LawsTechnologyEvaluationFlowDetailEO; import com.jero.modules.lawsTechnologyEvaluation.service.ILawsTechnologyEvaluationEOService; import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; import com.baomidou.mybatisplus.core.metadata.IPage; import com.baomidou.mybatisplus.extension.plugins.pagination.Page; +import com.jero.modules.lawsTechnologyEvaluation.service.ILawsTechnologyEvaluationFlowDetailEOService; +import com.jero.modules.system.service.ISysUserService; import lombok.extern.slf4j.Slf4j; import com.jero.common.system.base.controller.JeroController; +import org.apache.commons.collections4.CollectionUtils; +import org.apache.shiro.SecurityUtils; import org.apache.shiro.authz.annotation.RequiresPermissions; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.validation.annotation.Validated; @@ -40,6 +47,10 @@ import com.jero.common.aspect.annotation.AutoLog; public class LawsTechnologyEvaluationEOController extends JeroController { @Autowired private ILawsTechnologyEvaluationEOService lawsTechnologyEvaluationEOService; + @Autowired + private ISysUserService sysUserService; + @Autowired + private ILawsTechnologyEvaluationFlowDetailEOService lawsTechnologyEvaluationFlowDetailEOService; /** * 分页列表查询 @@ -60,6 +71,10 @@ public class LawsTechnologyEvaluationEOController extends JeroController queryWrapper = QueryGenerator.initQueryWrapper(lawsTechnologyEvaluationEO, req.getParameterMap()); queryWrapper.orderByDesc("start_time"); + boolean administrator = this.sysUserService.isAdministrator(); + if(!administrator){ + this.lawsTechnologyEvaluationEOService.createQueryPermission(queryWrapper,lawsTechnologyEvaluationEO,administrator); + } Page page = new Page(pageNo, pageSize); IPage pageList = lawsTechnologyEvaluationEOService.page(page, queryWrapper); this.lawsTechnologyEvaluationEOService.disposeData(pageList.getRecords(),cut); diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/lawsTechnologyEvaluation/entity/LawsTechnologyEvaluationEO.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/lawsTechnologyEvaluation/entity/LawsTechnologyEvaluationEO.java index 37a7d210f..5cb9f2248 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/lawsTechnologyEvaluation/entity/LawsTechnologyEvaluationEO.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/lawsTechnologyEvaluation/entity/LawsTechnologyEvaluationEO.java @@ -149,4 +149,7 @@ public class LawsTechnologyEvaluationEO implements Serializable { @ApiModelProperty(value = "流程编号") private String prcNum; + /**删除标识 true 可以删除,false,没有权限删除**/ + @TableField(exist = false) + private boolean deleteFlag = false; } diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/lawsTechnologyEvaluation/service/ILawsTechnologyEvaluationEOService.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/lawsTechnologyEvaluation/service/ILawsTechnologyEvaluationEOService.java index b2bad56ff..83138cd5f 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/lawsTechnologyEvaluation/service/ILawsTechnologyEvaluationEOService.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/lawsTechnologyEvaluation/service/ILawsTechnologyEvaluationEOService.java @@ -1,6 +1,7 @@ package com.jero.modules.lawsTechnologyEvaluation.service; import com.alibaba.fastjson.JSONObject; +import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; import com.baomidou.mybatisplus.core.metadata.IPage; import com.jero.common.api.vo.Result; import com.jero.modules.lawsTechnologyEvaluation.entity.LawsTechnologyEvaluationEO; @@ -92,4 +93,6 @@ public interface ILawsTechnologyEvaluationEOService extends IService batchCompleteTask(JSONObject jsonObject); + + void createQueryPermission(QueryWrapper queryWrapper, LawsTechnologyEvaluationEO lawsTechnologyEvaluationEO,boolean administrator); } diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/lawsTechnologyEvaluation/service/impl/LawsTechnologyEvaluationEOServiceImpl.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/lawsTechnologyEvaluation/service/impl/LawsTechnologyEvaluationEOServiceImpl.java index ac77d8994..cefc08e86 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/lawsTechnologyEvaluation/service/impl/LawsTechnologyEvaluationEOServiceImpl.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/lawsTechnologyEvaluation/service/impl/LawsTechnologyEvaluationEOServiceImpl.java @@ -9,6 +9,7 @@ import com.jero.common.constant.enums.CutEnum; import com.jero.common.constant.enums.MessageTypeEnum; import com.jero.common.constant.enums.ModuleEnum; import com.jero.common.exception.JeroBootException; +import com.jero.common.system.vo.LoginUser; import com.jero.generater.modules.online.cgform.entity.OnlCgformField; import com.jero.generater.modules.online.cgform.service.impl.OnlCgformFieldServiceImpl; import com.jero.modules.document.enums.FieldTypeEnum; @@ -39,6 +40,7 @@ import org.apache.commons.lang3.StringUtils; import org.apache.poi.hssf.usermodel.HSSFSheet; import org.apache.poi.hssf.usermodel.HSSFWorkbook; import org.apache.poi.ss.usermodel.*; +import org.apache.shiro.SecurityUtils; import org.jeecg.modules.jmreport.common.constant.CommonConstant; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Value; @@ -229,6 +231,8 @@ public class LawsTechnologyEvaluationEOServiceImpl extends ServiceImpl datas, String cut) { if(CollectionUtils.isNotEmpty(datas)){ + boolean administrator = this.sysUserService.isAdministrator(); + LoginUser currentUser = (LoginUser) SecurityUtils.getSubject().getPrincipal(); List categoryList = sysCategoryService.list(); for (LawsTechnologyEvaluationEO data : datas) { if(StringUtils.isNotEmpty(data.getEvaluationMethods())){ @@ -244,6 +248,9 @@ public class LawsTechnologyEvaluationEOServiceImpl extends ServiceImpl().success("手动结束成功!"); } + @Override + public void createQueryPermission(QueryWrapper queryWrapper, LawsTechnologyEvaluationEO lawsTechnologyEvaluationEO,boolean administrator) { + if(!administrator){ + //如果不是超级管理员,获取自己创建的和所有参与过的法规技术评估数据。 + LoginUser currentUser = (LoginUser) SecurityUtils.getSubject().getPrincipal(); + + QueryWrapper flowDetailQueryWrap = new QueryWrapper<>(); + flowDetailQueryWrap.lambda().eq(LawsTechnologyEvaluationFlowDetailEO::getEvaluatorId,currentUser.getId()); + List flowDetailEOList = this.lawsTechnologyEvaluationFlowDetailEOService.list(flowDetailQueryWrap); + if(CollectionUtils.isNotEmpty(flowDetailEOList)){ + List lawsTechnologyEvaluationIdList = flowDetailEOList.stream().map(LawsTechnologyEvaluationFlowDetailEO::getLawsTechnologyEvaluationId).distinct().collect(Collectors.toList()); + queryWrapper.and(query -> { + query.eq("create_by",currentUser.getUsername()); + query.or(q -> { + for (String lawsTechnologyEvaluationId : lawsTechnologyEvaluationIdList) { + q.or().like("id",lawsTechnologyEvaluationId); + } + }); + }); + } + } + } + private String getTreeName(String cut, List categoryList, List technologyTerritoryList) { StringBuilder sb = new StringBuilder(); for (String technologyTerritory : technologyTerritoryList) { From 63f471e7ecb1116c41abf10c95baee142cc27b07 Mon Sep 17 00:00:00 2001 From: zhn <947514737@qq.com> Date: Thu, 13 Oct 2022 18:07:01 +0800 Subject: [PATCH 066/251] =?UTF-8?q?=E6=B3=95=E8=A7=84=E6=9C=88=E6=8A=A5?= =?UTF-8?q?=E5=A1=AB=E5=86=99--=E5=88=97=E8=A1=A8=E6=8E=92=E5=BA=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../LawsMonthlyReportWriteEOController.java | 25 ++- .../LawsMonthlyReportTitleTemplateEO.java | 9 +- .../ILawsMonthlyReportWriteEOService.java | 9 +- .../LawsMonthlyReportWriteEOServiceImpl.java | 194 +++++++++++++++++- 4 files changed, 225 insertions(+), 12 deletions(-) diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/report/controller/LawsMonthlyReportWriteEOController.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/report/controller/LawsMonthlyReportWriteEOController.java index e4fb26d4e..b47ddcb11 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/report/controller/LawsMonthlyReportWriteEOController.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/report/controller/LawsMonthlyReportWriteEOController.java @@ -1,6 +1,7 @@ package com.jero.modules.report.controller; import com.baomidou.mybatisplus.core.metadata.IPage; +import com.baomidou.mybatisplus.extension.plugins.pagination.Page; import com.jero.common.api.vo.Result; import com.jero.common.aspect.annotation.AutoLog; import com.jero.common.system.base.controller.JeroController; @@ -62,9 +63,29 @@ public class LawsMonthlyReportWriteEOController extends JeroController pageList = lawsMonthlyReportWriteEOService.getPageInfo(lawsMonthlyReportWriteEO, pageNo,pageSize,req); - return Result.OK(pageList); + List listInfo = lawsMonthlyReportWriteEOService.getListInfo(lawsMonthlyReportWriteEO, pageNo, pageSize, req); + Page pages = lawsMonthlyReportWriteEOService.getPages(pageNo, pageSize, listInfo); + return Result.OK(pages); } +// /** +// * 分页列表查询 +// * +// * @param lawsMonthlyReportWriteEO +// * @param pageNo +// * @param pageSize +// * @param req +// * @return +// */ +// @AutoLog(value = "月报填写-分页列表查询") +// @ApiOperation(value="月报填写-分页列表查询", notes="月报填写-分页列表查询") +// @GetMapping(value = "/page") +// public Result queryPageList(LawsMonthlyReportWriteEO lawsMonthlyReportWriteEO, +// @RequestParam(name="pageNo", defaultValue="1") Integer pageNo, +// @RequestParam(name="pageSize", defaultValue="10") Integer pageSize, +// HttpServletRequest req) { +// IPage pageList = lawsMonthlyReportWriteEOService.getPageInfo(lawsMonthlyReportWriteEO, pageNo,pageSize,req); +// return Result.OK(pageList); +// } /** * 列表查询 diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/report/entity/LawsMonthlyReportTitleTemplateEO.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/report/entity/LawsMonthlyReportTitleTemplateEO.java index 4a66c3f86..9bd5daf0f 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/report/entity/LawsMonthlyReportTitleTemplateEO.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/report/entity/LawsMonthlyReportTitleTemplateEO.java @@ -13,7 +13,6 @@ import lombok.experimental.Accessors; import org.jeecgframework.poi.excel.annotation.Excel; import org.springframework.format.annotation.DateTimeFormat; -import java.io.Serializable; import java.util.ArrayList; import java.util.List; @@ -29,7 +28,7 @@ import java.util.List; @Accessors(chain = true) @EqualsAndHashCode(callSuper = false) @ApiModel(value="laws_monthly_report_title_template对象", description="月报标题模板") -public class LawsMonthlyReportTitleTemplateEO implements Serializable { +public class LawsMonthlyReportTitleTemplateEO implements Comparable { private static final long serialVersionUID = 1L; /**主键*/ @@ -84,4 +83,10 @@ public class LawsMonthlyReportTitleTemplateEO implements Serializable { @TableField(exist = false) private String key; + + @Override + public int compareTo(LawsMonthlyReportTitleTemplateEO o) { + return this.sort-o.sort;//升序 +// return o.id-this.id;//降序 + } } diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/report/service/ILawsMonthlyReportWriteEOService.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/report/service/ILawsMonthlyReportWriteEOService.java index 2f653b1b2..9bcf996c6 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/report/service/ILawsMonthlyReportWriteEOService.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/report/service/ILawsMonthlyReportWriteEOService.java @@ -1,6 +1,7 @@ package com.jero.modules.report.service; import com.baomidou.mybatisplus.core.metadata.IPage; +import com.baomidou.mybatisplus.extension.plugins.pagination.Page; import com.baomidou.mybatisplus.extension.service.IService; import com.jero.modules.report.entity.LawsMonthlyReportWriteEO; @@ -72,7 +73,11 @@ public interface ILawsMonthlyReportWriteEOService extends IService getPageInfo(LawsMonthlyReportWriteEO lawsMonthlyReportWriteEO, +// IPage getPageInfo(LawsMonthlyReportWriteEO lawsMonthlyReportWriteEO, +// Integer pageNo, +// Integer pageSize, +// HttpServletRequest req); + List getListInfo(LawsMonthlyReportWriteEO lawsMonthlyReportWriteEO, Integer pageNo, Integer pageSize, HttpServletRequest req); @@ -82,4 +87,6 @@ public interface ILawsMonthlyReportWriteEOService extends IService parameter); + + Page getPages(Integer currentPage, Integer pageSize, List list); } diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/report/service/impl/LawsMonthlyReportWriteEOServiceImpl.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/report/service/impl/LawsMonthlyReportWriteEOServiceImpl.java index 12fc10c4d..0b8f0f108 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/report/service/impl/LawsMonthlyReportWriteEOServiceImpl.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/report/service/impl/LawsMonthlyReportWriteEOServiceImpl.java @@ -60,8 +60,10 @@ import java.io.IOException; import java.io.OutputStream; import java.util.ArrayList; import java.util.Arrays; +import java.util.Collections; import java.util.Date; import java.util.Iterator; +import java.util.LinkedList; import java.util.List; import java.util.Map; import java.util.stream.Collectors; @@ -288,7 +290,7 @@ public class LawsMonthlyReportWriteEOServiceImpl extends ServiceImpl getPageInfo(LawsMonthlyReportWriteEO lawsMonthlyReportWriteEOTemp, + public List getListInfo(LawsMonthlyReportWriteEO lawsMonthlyReportWriteEOTemp, Integer pageNo, Integer pageSize, HttpServletRequest req) { @@ -300,11 +302,48 @@ public class LawsMonthlyReportWriteEOServiceImpl extends ServiceImpl page = new Page(pageNo, pageSize); - Page pageInfo = this.page(page, queryWrapper); +// Page page = new Page(pageNo, pageSize); +// Page pageInfo = this.page(page, queryWrapper); + + + //所有的月报 + List lawsMonthlyReportWriteEOList = this.list(queryWrapper); + //所有月报的一级目录 + List oneMenuIdLIst = lawsMonthlyReportWriteEOList.stream().map(LawsMonthlyReportWriteEO::getMemoriesChapterOne).distinct().collect(Collectors.toList()); + //月报标题模板 + LambdaQueryWrapper wrapperTemp = new LambdaQueryWrapper<>(); + wrapperTemp.orderByAsc(LawsMonthlyReportTitleTemplateEO::getSort); + List list = lawsMonthlyReportTitleTemplateEOService.list(wrapperTemp); + //1. 一级目录 + List oneList = list.stream().filter(e -> StringUtils.isBlank(e.getParentId())).collect(Collectors.toList()); + oneList = oneList.stream().filter(e -> oneMenuIdLIst.contains(e.getId())).collect(Collectors.toList()); + Collections.sort(oneList);//正序排序 + + List lawsMonthlyReportWriteEOS = new LinkedList<>(); + for (LawsMonthlyReportTitleTemplateEO lawsMonthlyReportTitleTemplateEO : oneList) { + String oneId = lawsMonthlyReportTitleTemplateEO.getId(); + //一级目录下的二级目录 + List twoList = list.stream().filter(e -> StringUtils.isNotBlank(e.getParentId()) && oneId.equals(e.getParentId())).collect(Collectors.toList()); + Collections.sort(twoList);//正序排序 + + //一级目录下的月报 + for (LawsMonthlyReportTitleTemplateEO monthlyReportTitleTemplateEO : twoList) { + for (LawsMonthlyReportWriteEO lawsMonthlyReportWriteEO : lawsMonthlyReportWriteEOList) { + if(oneId.equals(lawsMonthlyReportWriteEO.getMemoriesChapterOne()) && monthlyReportTitleTemplateEO.getId().equals(lawsMonthlyReportWriteEO.getMemoriesChapter())){ + lawsMonthlyReportWriteEOS.add(lawsMonthlyReportWriteEO); + } + } + } + +// List lawsMonthlyReportWriteEOListOne = lawsMonthlyReportWriteEOList.stream() +// .filter(e -> oneId.equals(e.getMemoriesChapterOne())).collect(Collectors.toList()); +// lawsMonthlyReportWriteEOS.addAll(lawsMonthlyReportWriteEOListOne); + } + + //法规月报id - List lawsMonthlyReportIdList = pageInfo.getRecords().stream().map(LawsMonthlyReportWriteEO::getId).collect(Collectors.toList()); - List userIdList = pageInfo.getRecords().stream().map(LawsMonthlyReportWriteEO::getLawsContact).collect(Collectors.toList()); + List lawsMonthlyReportIdList = lawsMonthlyReportWriteEOS.stream().map(LawsMonthlyReportWriteEO::getId).collect(Collectors.toList()); + List userIdList = lawsMonthlyReportWriteEOS.stream().map(LawsMonthlyReportWriteEO::getLawsContact).collect(Collectors.toList()); List userIds = new ArrayList<>(); for (String s : userIdList) { if(StringUtils.isNotBlank(s)){ @@ -343,7 +382,7 @@ public class LawsMonthlyReportWriteEOServiceImpl extends ServiceImpl getPageInfo(LawsMonthlyReportWriteEO lawsMonthlyReportWriteEOTemp, +// Integer pageNo, +// Integer pageSize, +// HttpServletRequest req) { +// QueryWrapper queryWrapper = QueryGenerator.initQueryWrapper(lawsMonthlyReportWriteEOTemp, req.getParameterMap()); +// queryWrapper.orderByDesc("memories_chapter_one","memories_chapter","create_time"); +// //管理员查看全部数据,其余人只能查看自己的数据 +// LoginUser currentUser = (LoginUser) SecurityUtils.getSubject().getPrincipal(); +// List rolesList = sysBaseApi.getRolesByUsername(currentUser.getUsername()); +// if(!rolesList.contains(ProjectRoleEnum.ADMIN.getCode())){ +// queryWrapper.in("create_by",currentUser.getUsername()); +// } +// Page page = new Page(pageNo, pageSize); +// Page pageInfo = this.page(page, queryWrapper); +// //法规月报id +// List lawsMonthlyReportIdList = pageInfo.getRecords().stream().map(LawsMonthlyReportWriteEO::getId).collect(Collectors.toList()); +// List userIdList = pageInfo.getRecords().stream().map(LawsMonthlyReportWriteEO::getLawsContact).collect(Collectors.toList()); +// List userIds = new ArrayList<>(); +// for (String s : userIdList) { +// if(StringUtils.isNotBlank(s)){ +// if(s.contains(",")){ +// userIds.addAll(Arrays.asList(s.split(","))); +// }else{ +// userIds.add(s); +// } +// } +// } +// List jsonObjects = sysBaseApi.queryUsersByIds(StringUtils.join(userIds, ",")); +// List userList = new ArrayList<>(); +// for (JSONObject jsonObject : jsonObjects) { +// LoginUser loginUser = JSONObject.parseObject(jsonObject.toJSONString(), LoginUser.class); +// userList.add(loginUser); +// } +// +// //获取章节目录 +// List lawsMonthlyReportTitleTemplateEOList = lawsMonthlyReportTitleTemplateEOService.list(); +// +// //新征求意见清单模板 +// List newOpinionTemplateEOList = new ArrayList<>(); +// if(lawsMonthlyReportIdList.size() != 0){ +// LambdaQueryWrapper wrapper = new LambdaQueryWrapper<>(); +// wrapper.in(NewOpinionTemplateEO::getLawsMonthlyReportWriteId,lawsMonthlyReportIdList); +// newOpinionTemplateEOList = iNewOpinionTemplateEOService.list(wrapper); +// } +// +// +// //新发布标准清单模板 +// List newStandardTemplateEOList = new ArrayList<>(); +// if(lawsMonthlyReportIdList.size() != 0){ +// LambdaQueryWrapper qrapperTemp = new LambdaQueryWrapper<>(); +// qrapperTemp.in(NewStandardTemplateEO::getLawsMonthlyReportWriteId,lawsMonthlyReportIdList); +// newStandardTemplateEOList = iNewStandardTemplateEOService.list(qrapperTemp); +// } +// +// +// for (LawsMonthlyReportWriteEO lawsMonthlyReportWriteEO : pageInfo.getRecords()) { +// //处理法规联系人 +// lawsContact(userList, lawsMonthlyReportWriteEO,lawsMonthlyReportWriteEOTemp.getCut()); +// //处理章节目录 +// if(StringUtils.isNotBlank(lawsMonthlyReportWriteEO.getMemoriesChapter())){ +// List lawsMonthlyReportTitleTemplateEOS = lawsMonthlyReportTitleTemplateEOList.stream() +// .filter(e -> lawsMonthlyReportWriteEO.getMemoriesChapter().equals(e.getId())).collect(Collectors.toList()); +// if(CutEnum.CN.getValue().equals(lawsMonthlyReportWriteEOTemp.getCut()) && lawsMonthlyReportTitleTemplateEOS.size() != 0){ +// lawsMonthlyReportWriteEO.setMemoriesChapterName(lawsMonthlyReportTitleTemplateEOS.get(0).getTitleCn()); +// }else if(CutEnum.EN.getValue().equals(lawsMonthlyReportWriteEOTemp.getCut()) && lawsMonthlyReportTitleTemplateEOS.size() != 0){ +// lawsMonthlyReportWriteEO.setMemoriesChapterName(lawsMonthlyReportTitleTemplateEOS.get(0).getTitleEn()); +// } +// } +// //处理章节目录对应的一级目录 +// if(StringUtils.isNotBlank(lawsMonthlyReportWriteEO.getMemoriesChapterOne())){ +// List lawsMonthlyReportTitleTemplateEOS = lawsMonthlyReportTitleTemplateEOList.stream() +// .filter(e -> lawsMonthlyReportWriteEO.getMemoriesChapterOne().equals(e.getId())).collect(Collectors.toList()); +// if(CutEnum.CN.getValue().equals(lawsMonthlyReportWriteEOTemp.getCut()) && lawsMonthlyReportTitleTemplateEOS.size() != 0){ +// lawsMonthlyReportWriteEO.setMemoriesChapterOneName(lawsMonthlyReportTitleTemplateEOS.get(0).getTitleCn()); +// }else if(CutEnum.EN.getValue().equals(lawsMonthlyReportWriteEOTemp.getCut()) && lawsMonthlyReportTitleTemplateEOS.size() != 0){ +// lawsMonthlyReportWriteEO.setMemoriesChapterOneName(lawsMonthlyReportTitleTemplateEOS.get(0).getTitleEn()); +// } +// } +// +// if(ContentTemplateEnum.NEW_REQUEST_LIST_TEMPLATE.getValue().equals(lawsMonthlyReportWriteEO.getContentTemplate())){ +// //新征求意见清单模板 +// List collect = newOpinionTemplateEOList.stream() +// .filter(e -> lawsMonthlyReportWriteEO.getId().equals(e.getLawsMonthlyReportWriteId())).collect(Collectors.toList()); +// lawsMonthlyReportWriteEO.setNewOpinionTemplateEOList(collect); +// +// }else if(ContentTemplateEnum.NEW_RELEASE_STANDARD_MANIFEST_TEMPLATE.getValue().equals(lawsMonthlyReportWriteEO.getContentTemplate())){ +// //新发布标准清单模板 +// List collect = newStandardTemplateEOList.stream() +// .filter(e -> lawsMonthlyReportWriteEO.getId().equals(e.getLawsMonthlyReportWriteId())).collect(Collectors.toList()); +// lawsMonthlyReportWriteEO.setNewStandardTemplateEOList(collect); +// } +// +// //处理导出状态 +// String exportState = lawsMonthlyReportWriteEO.getExportState(); +// if(StringUtils.isNotBlank(exportState)){ +// if(ExportStateEnum.NOT_EXPORT.getValue().equals(exportState)){ +// if(CutEnum.CN.getValue().equals(lawsMonthlyReportWriteEOTemp.getCut())){ +// lawsMonthlyReportWriteEO.setExportStateName(ExportStateEnum.NOT_EXPORT.getName()); +// }else{ +// lawsMonthlyReportWriteEO.setExportStateName(ExportStateEnum.NOT_EXPORT.getNameEn()); +// } +// }else if(ExportStateEnum.HAS_BEEN_EXPORT.getValue().equals(exportState)){ +// if(CutEnum.CN.getValue().equals(lawsMonthlyReportWriteEOTemp.getCut())){ +// lawsMonthlyReportWriteEO.setExportStateName(ExportStateEnum.HAS_BEEN_EXPORT.getName()); +// }else{ +// lawsMonthlyReportWriteEO.setExportStateName(ExportStateEnum.HAS_BEEN_EXPORT.getNameEn()); +// } +// } +// } +// } +// return pageInfo; +// } private void lawsContact(List userList, LawsMonthlyReportWriteEO lawsMonthlyReportWriteEO,String cut) { String lawsContact = lawsMonthlyReportWriteEO.getLawsContact(); @@ -1269,4 +1421,32 @@ public class LawsMonthlyReportWriteEOServiceImpl extends ServiceImpl list){ + Page page =new Page(); + if(list==null){ + return null; + } + int size = list.size(); + if(pageSize > size){ + pageSize = size; + } + if(pageSize!=0){ + //求出最⼤页数,防⽌currentPage越界 + int maxPage = size % pageSize ==0? size / pageSize : size / pageSize +1; + if(currentPage > maxPage){ + currentPage = maxPage; + } + } + //当前页第⼀条数据的下标 + int curIdx = currentPage >1?(currentPage -1)* pageSize :0; + List pageList =new ArrayList(); + //将当前页的数据放进pageList + for(int i =0; i < pageSize && curIdx + i < size; i++){ + pageList.add(list.get(curIdx + i)); + } + page.setCurrent(currentPage).setSize(pageSize).setTotal(list.size()).setRecords(pageList); + return page; + } + } From 12041eb48ad7625f748a65e5efd28c15945a6f14 Mon Sep 17 00:00:00 2001 From: liyawei Date: Fri, 14 Oct 2022 11:38:23 +0800 Subject: [PATCH 067/251] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E6=9F=A5=E8=AF=A2?= =?UTF-8?q?=E6=89=80=E6=9C=89=E5=AD=90=E9=83=A8=E9=97=A8=E6=96=B9=E6=B3=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../service/impl/SysDepartServiceImpl.java | 34 ++++++++++++++++++- 1 file changed, 33 insertions(+), 1 deletion(-) diff --git a/jero-boot/jero-boot-module-system/src/main/java/com/jero/modules/system/service/impl/SysDepartServiceImpl.java b/jero-boot/jero-boot-module-system/src/main/java/com/jero/modules/system/service/impl/SysDepartServiceImpl.java index 02027b250..8c5c3d639 100644 --- a/jero-boot/jero-boot-module-system/src/main/java/com/jero/modules/system/service/impl/SysDepartServiceImpl.java +++ b/jero-boot/jero-boot-module-system/src/main/java/com/jero/modules/system/service/impl/SysDepartServiceImpl.java @@ -1,5 +1,6 @@ package com.jero.modules.system.service.impl; +import cn.hutool.core.collection.CollectionUtil; import com.alibaba.fastjson.JSONObject; import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; @@ -24,6 +25,7 @@ import org.springframework.stereotype.Service; import org.springframework.transaction.annotation.Transactional; import java.util.*; +import java.util.stream.Collectors; import static com.jero.modules.system.util.FindsDepartsChildrenUtil.convertSysDepartToSysDepartTreeModel; @@ -286,7 +288,37 @@ public class SysDepartServiceImpl extends ServiceImpl getSubDepIdsByDepId(String departId) { - return this.baseMapper.getSubDepIdsByDepId(departId); + List idList = new ArrayList<>(); + if(StringUtils.isNotEmpty(departId)) { + // 查询所有部门 + LambdaQueryWrapper query = new LambdaQueryWrapper(); + query.eq(SysDepart::getDelFlag, CommonConstant.DEL_FLAG_0.toString()); + List listAll = this.list(query); + + List result = new ArrayList<>(); + // 递归查询 指定父节点下的所有子节点,包括父节点 + if (CollectionUtil.isNotEmpty(listAll)) { + recursion(listAll, result, departId); + } + + + idList.add(departId); // 加上父节点 + idList = result.stream().map(SysDepart::getId).collect(Collectors.toList()); + + } + return idList; + } + + // 递归查询子节点 + private void recursion(List listAll, List result, String fatherId) { + List childern = listAll.stream().filter(e-> fatherId.equals(e.getParentId())).collect(Collectors.toList()); + if (CollectionUtil.isNotEmpty(childern)) { + result.addAll(childern); + for(SysDepart depart : childern) { + recursion(listAll, result, depart.getId()); + } + + } } @Override From f3327acc20ebba31ca090770597dfb0c91ca1cd6 Mon Sep 17 00:00:00 2001 From: zhn <947514737@qq.com> Date: Fri, 14 Oct 2022 12:00:03 +0800 Subject: [PATCH 068/251] =?UTF-8?q?=E6=9C=88=E6=8A=A5=E5=AF=BC=E5=87=BA--o?= =?UTF-8?q?ffice=E7=89=88=E6=9C=AC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../LawsMonthlyReportWriteEOServiceImpl.java | 103 +++++++++- .../jero/modules/report/util/WordUtil.java | 191 +++++++++++++----- 2 files changed, 240 insertions(+), 54 deletions(-) diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/report/service/impl/LawsMonthlyReportWriteEOServiceImpl.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/report/service/impl/LawsMonthlyReportWriteEOServiceImpl.java index 0b8f0f108..cb571424d 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/report/service/impl/LawsMonthlyReportWriteEOServiceImpl.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/report/service/impl/LawsMonthlyReportWriteEOServiceImpl.java @@ -1025,17 +1025,26 @@ public class LawsMonthlyReportWriteEOServiceImpl extends ServiceImpl lawsMonthlyReportWriteEOS, String titleCN, XWPFDocument document) { //封面标识 String flag = "cover"; String moth = lawsMonthlyReportWriteEOS.get(0).getMonth().replaceAll("-", "年") + "月"; + //标题前面添加一个换行 + WordUtil.exportWord(document, "", null, ParagraphAlignment.CENTER, 0, null, + false, false, "Blue Sky Noto Regular",null,null,"break"); - titleCN = "\r\n\r\n" + titleCN + "\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n"; + //添加标题 WordUtil.exportWord(document, titleCN, null, ParagraphAlignment.CENTER, 0, 18, false, false, "Blue Sky Noto Regular",null,null,flag); + + //标题下面添加9个换行 + for (int i = 0; i < 9; i++) { + WordUtil.exportWord(document, "", null, ParagraphAlignment.CENTER, 0, null, + false, false, "Blue Sky Noto Regular",null,null,"break"); + } WordUtil.exportWord(document, moth, null, ParagraphAlignment.CENTER, 0, 12, false, false, "Blue Sky Noto Regular",null,null,flag); @@ -1060,7 +1069,42 @@ public class LawsMonthlyReportWriteEOServiceImpl extends ServiceImpl lawsMonthlyReportWriteEOS, +// String titleCN, +// XWPFDocument document) { +// //封面标识 +// String flag = "cover"; +// String moth = lawsMonthlyReportWriteEOS.get(0).getMonth().replaceAll("-", "年") + "月"; +// +// titleCN = "\r\n\r\n" + titleCN + "\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n"; +// WordUtil.exportWord(document, titleCN, null, ParagraphAlignment.CENTER, 0, 18, +// false, false, "Blue Sky Noto Regular",null,null,flag); +// WordUtil.exportWord(document, moth, null, ParagraphAlignment.CENTER, 0, 12, +// false, false, "Blue Sky Noto Regular",null,null,flag); +// +// String year = lawsMonthlyReportWriteEOS.get(0).getMonth().split("-")[0]; +// String mothNew = lawsMonthlyReportWriteEOS.get(0).getMonth().split("-")[1]; +// int mothLast = Integer.valueOf(mothNew) + 1; +// +// //添加说明 2022/7/15 至 2022/8/14 期间发布的主要内容 +// String text = year + "/" + mothNew +"/15 至 "+year+"/"+mothLast+"/14期间发布的主要内容"; +// WordUtil.exportWord(document, text, null, ParagraphAlignment.CENTER, 0, 11, +// false, false, "Blue Sky Noto Regular",null,null,flag); +// +// //添加换行 +// WordUtil.exportWord(document, "\r\n", null, ParagraphAlignment.CENTER, 0, null, +// false, false, null,null,null,flag); +// +// //添加说明 编辑: 整车工程 - 法规与认证&环保与材料科团队 +// String text1 = "编辑: 整车工程 - 法规与认证&环保与材料科团队"; +// WordUtil.exportWord(document, text1, null, ParagraphAlignment.CENTER, 0, 11, +// false, false, "Blue Sky Noto Regular",null,null,flag); +// +// //添加下一页 +// document.createParagraph().createRun().addBreak(BreakType.PAGE); +// } + //封面(office版本) private void coverEn(List lawsMonthlyReportWriteEOS, String titleCN, XWPFDocument document) { @@ -1074,11 +1118,19 @@ public class LawsMonthlyReportWriteEOServiceImpl extends ServiceImpl lawsMonthlyReportWriteEOS, +// String titleCN, +// XWPFDocument document) { +// //封面标识 +// String flag = "cover"; +// +// String year = lawsMonthlyReportWriteEOS.get(0).getMonth().split("-")[0]; +// String mothNew = lawsMonthlyReportWriteEOS.get(0).getMonth().split("-")[1]; +// int mothLast = Integer.valueOf(mothNew) + 1; +// String moth = mothNew+"/"+year; +// String mothNewEn = getMothEn(mothNew); +// String mothLastEn = getMothEn(String.valueOf(mothLast)); +// +//// String moth = lawsMonthlyReportWriteEOS.get(0).getMonth().replaceAll("-", "年") + "月"; +// +// titleCN = "\r\n\r\n" + titleCN + "\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n"; +// WordUtil.exportWord(document, titleCN, null, ParagraphAlignment.CENTER, 0, 18, +// false, false, "Blue Sky Noto Regular",null,null,flag); +// WordUtil.exportWord(document, moth, null, ParagraphAlignment.CENTER, 0, 12, +// false, false, "Blue Sky Noto Regular",null,null,flag); +// +// +// +// //添加说明 Update between July 15, 2022 and August 14, 2022 +// String text = "Update between "+mothNewEn+" 15,"+year+" and "+mothLastEn+" 14,"+year; +// WordUtil.exportWord(document, text, null, ParagraphAlignment.CENTER, 0, 11, +// false, false, "Blue Sky Noto Regular",null,null,flag); +// +// //添加换行 +// WordUtil.exportWord(document, "\r\n", null, ParagraphAlignment.CENTER, 0, null, +// false, false, null,null,null,flag); +// +// //添加说明 编辑: 整车工程 - 法规与认证&环保与材料科团队 +// String text1 = "Edit By: Regulation & Homologation, Environmental & Materials Team"; +// WordUtil.exportWord(document, text1, null, ParagraphAlignment.CENTER, 0, 11, +// false, false, "Blue Sky Noto Regular",null,null,flag); +// +// //添加下一页 +// document.createParagraph().createRun().addBreak(BreakType.PAGE); +// } private String getMothEn(String moth){ String result = ""; 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 048c0ee08..ddf6347d9 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 @@ -128,6 +128,10 @@ public class WordUtil { } XWPFRun titleParagraphRun = titleParagraph.createRun(); + //封面中的换行 + if("break".equals(flag)){ + titleParagraphRun.addBreak(); + } if (isNewline) { titleParagraphRun.setText("\r"); } else { @@ -202,45 +206,7 @@ public class WordUtil { styles.addStyle(style); } -// @SneakyThrows -// public static void exportHeardAndFoot(XWPFDocument document){ -//// XWPFDocument document = new XWPFDocument(); -// -// // create header-footer -// XWPFHeaderFooterPolicy headerFooterPolicy = document.getHeaderFooterPolicy(); -// if (headerFooterPolicy == null) headerFooterPolicy = document.createHeaderFooterPolicy(); -// -// // create header start -// XWPFHeader header = headerFooterPolicy.createHeader(XWPFHeaderFooterPolicy.DEFAULT); -// -// XWPFParagraph paragraph = header.createParagraph(); -// paragraph.setAlignment(ParagraphAlignment.CENTER); -// -// XWPFRun run = paragraph.createRun(); -// run.setText("Header"); -// -// // create footer start -// XWPFFooter footer = headerFooterPolicy.createFooter(XWPFHeaderFooterPolicy.DEFAULT); -// -// paragraph = footer.createParagraph(); -// paragraph.setAlignment(ParagraphAlignment.CENTER); -// -// run = paragraph.createRun(); -// run.setText("Footer"); -// -// CTSectPr sectPr = document.getDocument().getBody().getSectPr(); -// if (sectPr == null) sectPr = document.getDocument().getBody().addNewSectPr(); -// CTPageMar pageMar = sectPr.getPgMar(); -// if (pageMar == null) pageMar = sectPr.addNewPgMar(); -// pageMar.setLeft(BigInteger.valueOf(2000)); //720 TWentieths of an Inch Point (Twips) = 720/20 = 36 pt = 36/72 = 0.5" -// pageMar.setRight(BigInteger.valueOf(720)); -// pageMar.setTop(BigInteger.valueOf(1440)); //1440 Twips = 1440/20 = 72 pt = 72/72 = 1" -// pageMar.setBottom(BigInteger.valueOf(1440)); -// -// pageMar.setHeader(BigInteger.valueOf(2000)); //45.4 pt * 20 = 908 = 45.4 pt header from top -// pageMar.setFooter(BigInteger.valueOf(568)); //28.4 pt * 20 = 568 = 28.4 pt footer from bottom -// -// } + //主要内容生成页眉页脚(office版本) @SneakyThrows public static void exportHeardAndFoot(XWPFDocument document,String month){ XWPFHeaderFooterPolicy headerFooterPolicy = document.getHeaderFooterPolicy(); @@ -266,7 +232,7 @@ public class WordUtil { picture.getCTPicture().getBlipFill().getBlip().setEmbed(blipID); run.addTab(); is.close(); - run.setText(" "+month); + run.setText(" "+month); run.setFontSize(11); run.setFontFamily("Blue Sky Noto Regular"); } @@ -313,20 +279,107 @@ public class WordUtil { CTSectPr sectPr = document.getDocument().getBody().getSectPr(); if (sectPr == null) sectPr = document.getDocument().getBody().addNewSectPr(); - //设置页面大小 + //设置页面大小(21*29.7) CTPageSz pgSz = sectPr.addNewPgSz(); - pgSz.setW(BigInteger.valueOf(11907)); - pgSz.setH(BigInteger.valueOf(16840)); + pgSz.setW(BigInteger.valueOf(11905)); + pgSz.setH(BigInteger.valueOf(16838)); CTPageMar pageMar = sectPr.getPgMar(); if (pageMar == null) pageMar = sectPr.addNewPgMar(); - pageMar.setLeft(BigInteger.valueOf(1803)); //左边距 - pageMar.setRight(BigInteger.valueOf(1803));//右边距 + pageMar.setLeft(BigInteger.valueOf(1797)); //左边距 + pageMar.setRight(BigInteger.valueOf(1797));//右边距 pageMar.setTop(BigInteger.valueOf(1440)); //页眉高度 pageMar.setBottom(BigInteger.valueOf(1440));//页脚高度 pageMar.setHeader(BigInteger.valueOf(720)); //页眉上边框到顶部的距离 pageMar.setFooter(BigInteger.valueOf(720)); //页脚下边框到底部的距离 } + //主要内容生成页眉页脚(WPS版本) +// @SneakyThrows +// public static void exportHeardAndFoot(XWPFDocument document,String month){ +// XWPFHeaderFooterPolicy headerFooterPolicy = document.getHeaderFooterPolicy(); +// if (headerFooterPolicy == null) headerFooterPolicy = document.createHeaderFooterPolicy(); +// XWPFHeader header = headerFooterPolicy.createHeader(XWPFHeaderFooterPolicy.DEFAULT); +// +//// String logoFilePath = "/jero-boot/home/weilai.png"; +// String logoFilePath = WordUtil.class.getClassLoader().getResource("static/home/weilai.png").getPath(); +// //页眉第一个段落展示logo----------------------------------------------------------------------------------- +// if (org.apache.commons.lang3.StringUtils.isNotBlank(logoFilePath)) { +// XWPFParagraph logo = header.createParagraph(); +// logo.setAlignment(ParagraphAlignment.LEFT); +// XWPFRun run = logo.createRun(); +// +// String imgFile = logoFilePath; +// InputStream is = WordUtil.class.getClassLoader().getResourceAsStream("static/home/weilai.png"); +//// InputStream is = new FileInputStream(imgFile); +// XWPFPicture picture = run.addPicture(is, XWPFDocument.PICTURE_TYPE_PNG, imgFile, Units.toEMU(95), Units.toEMU(35)); +// String blipID = ""; +// for(XWPFPictureData picturedata : header.getAllPackagePictures()) { //这段必须有,不然打开的logo图片不显示 +// blipID = header.getRelationId(picturedata); +// } +// picture.getCTPicture().getBlipFill().getBlip().setEmbed(blipID); +// run.addTab(); +// is.close(); +// run.setText(" "+month); +// run.setFontSize(11); +// run.setFontFamily("Blue Sky Noto Regular"); +// } +// //页眉第二个段落展示日期------------------------------------------------------------ +// XWPFParagraph paragraph = header.createParagraph();//创建新的段落 +//// paragraph.setAlignment(ParagraphAlignment.RIGHT);//段落文本的对齐方式 +// XWPFRun run = paragraph.createRun(); +//// run.setText(month); +// +// //页脚(三个段落分别展示3个内容)----------------------------------------------------- +// XWPFFooter footer = headerFooterPolicy.createFooter(XWPFHeaderFooterPolicy.DEFAULT); +// +// paragraph = footer.createParagraph(); +// paragraph.setAlignment(ParagraphAlignment.CENTER); +// run = paragraph.createRun(); +// run.setText("NIO Internal"); +// run.setFontSize(11); +// run.setFontFamily("Blue Sky Standard Regular"); +// +// paragraph = footer.createParagraph(); +// paragraph.setAlignment(ParagraphAlignment.LEFT); +// run = paragraph.createRun(); +// run.setText("NIO.com"); +// run.setFontSize(11); +// run.setFontFamily("Blue Sky Noto Regular"); +// +// //生成页码--------------------------------------------------------------------- +// paragraph = footer.createParagraph(); +// paragraph.setAlignment(ParagraphAlignment.RIGHT); +// run = paragraph.createRun(); +// CTFldChar fldChar = run.getCTR().addNewFldChar(); +// fldChar.setFldCharType(STFldCharType.Enum.forString("begin")); +// +// run = paragraph.createRun(); +// CTText ctText = run.getCTR().addNewInstrText(); +// ctText.setStringValue("PAGE \\* MERGEFORMAT"); +// ctText.setSpace(SpaceAttribute.Space.Enum.forString("preserve")); +// +// fldChar = run.getCTR().addNewFldChar(); +// fldChar.setFldCharType(STFldCharType.Enum.forString("end")); +// //---------------------------------------------------------------------------- +// +// +// +// CTSectPr sectPr = document.getDocument().getBody().getSectPr(); +// if (sectPr == null) sectPr = document.getDocument().getBody().addNewSectPr(); +// //设置页面大小 +// CTPageSz pgSz = sectPr.addNewPgSz(); +// pgSz.setW(BigInteger.valueOf(11907)); +// pgSz.setH(BigInteger.valueOf(16840)); +// CTPageMar pageMar = sectPr.getPgMar(); +// if (pageMar == null) pageMar = sectPr.addNewPgMar(); +// pageMar.setLeft(BigInteger.valueOf(1803)); //左边距 +// pageMar.setRight(BigInteger.valueOf(1803));//右边距 +// pageMar.setTop(BigInteger.valueOf(1440)); //页眉高度 +// pageMar.setBottom(BigInteger.valueOf(1440));//页脚高度 +// +// pageMar.setHeader(BigInteger.valueOf(720)); //页眉上边框到顶部的距离 +// pageMar.setFooter(BigInteger.valueOf(720)); //页脚下边框到底部的距离 +// } /** * 主页面(只有页脚) @@ -356,18 +409,58 @@ public class WordUtil { if (sectPr == null) sectPr = document.getDocument().getBody().addNewSectPr(); //设置页面大小 CTPageSz pgSz = sectPr.addNewPgSz(); - pgSz.setW(BigInteger.valueOf(11907)); - pgSz.setH(BigInteger.valueOf(16840)); + pgSz.setW(BigInteger.valueOf(11905)); + pgSz.setH(BigInteger.valueOf(16838)); CTPageMar pageMar = sectPr.getPgMar(); if (pageMar == null) pageMar = sectPr.addNewPgMar(); - pageMar.setLeft(BigInteger.valueOf(1803)); //左边距 - pageMar.setRight(BigInteger.valueOf(1803));//右边距 + pageMar.setLeft(BigInteger.valueOf(1797)); //左边距 + pageMar.setRight(BigInteger.valueOf(1797));//右边距 pageMar.setTop(BigInteger.valueOf(1440)); //页眉高度 pageMar.setBottom(BigInteger.valueOf(1440));//页脚高度 pageMar.setHeader(BigInteger.valueOf(500)); //页眉上边框到顶部的距离 pageMar.setFooter(BigInteger.valueOf(1200)); //页脚下边框到底部的距离 } +// /** +// * 主页面(只有页脚 WPS版本) +// * @param document +// * @param month +// */ +// @SneakyThrows +// public static void exportHeardAndFootMain(XWPFDocument document,String month){ +// XWPFHeaderFooterPolicy headerFooterPolicy = document.getHeaderFooterPolicy(); +// if (headerFooterPolicy == null) headerFooterPolicy = document.createHeaderFooterPolicy(); +//// XWPFHeader header = headerFooterPolicy.createHeader(XWPFHeaderFooterPolicy.DEFAULT); +//// XWPFParagraph paragraph = header.createParagraph();//创建新的段落 +//// XWPFRun run = paragraph.createRun(); +// +// XWPFFooter footer = headerFooterPolicy.createFooter(XWPFHeaderFooterPolicy.DEFAULT); +// XWPFParagraph paragraph = footer.createParagraph(); +// paragraph.setAlignment(ParagraphAlignment.CENTER); +// XWPFRun run = paragraph.createRun(); +// run.setText("NIO Internal"); +// run.setFontSize(18); +// run.setFontFamily("Blue Sky Standard Regular"); +//// run.setFontFamily("Blue Sky Noto Regular"); +// run.setBold(true); +// +// +// CTSectPr sectPr = document.getDocument().getBody().getSectPr(); +// if (sectPr == null) sectPr = document.getDocument().getBody().addNewSectPr(); +// //设置页面大小 +// CTPageSz pgSz = sectPr.addNewPgSz(); +// pgSz.setW(BigInteger.valueOf(11907)); +// pgSz.setH(BigInteger.valueOf(16840)); +// CTPageMar pageMar = sectPr.getPgMar(); +// if (pageMar == null) pageMar = sectPr.addNewPgMar(); +// pageMar.setLeft(BigInteger.valueOf(1803)); //左边距 +// pageMar.setRight(BigInteger.valueOf(1803));//右边距 +// pageMar.setTop(BigInteger.valueOf(1440)); //页眉高度 +// pageMar.setBottom(BigInteger.valueOf(1440));//页脚高度 +// +// pageMar.setHeader(BigInteger.valueOf(500)); //页眉上边框到顶部的距离 +// pageMar.setFooter(BigInteger.valueOf(1200)); //页脚下边框到底部的距离 +// } /** * 导出工具示例 From c51e215107729b782df98a132e536bd036cb7762 Mon Sep 17 00:00:00 2001 From: liyawei Date: Fri, 14 Oct 2022 14:49:40 +0800 Subject: [PATCH 069/251] =?UTF-8?q?=E6=96=87=E6=A1=A3=E6=8B=86=E5=88=86-?= =?UTF-8?q?=E6=B3=A8=E9=87=8A?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../service/impl/FileSplitItemsEOServiceImpl.java | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/split/service/impl/FileSplitItemsEOServiceImpl.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/split/service/impl/FileSplitItemsEOServiceImpl.java index c4c4dd28f..b7a5cb5fa 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/split/service/impl/FileSplitItemsEOServiceImpl.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/split/service/impl/FileSplitItemsEOServiceImpl.java @@ -576,13 +576,13 @@ public class FileSplitItemsEOServiceImpl extends ServiceImpl Date: Fri, 14 Oct 2022 15:18:01 +0800 Subject: [PATCH 070/251] =?UTF-8?q?=E5=B8=83=E5=B1=80=E9=A1=B9=E7=9B=AE?= =?UTF-8?q?=E5=BA=93=E5=8F=98=E6=9B=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- jero-web/src/common/lang/en-us.js | 1 + jero-web/src/common/lang/zh-cn.js | 1 + .../projectManagement/components/addModel.vue | 21 ++ .../components/changeExtensionModel.vue | 263 ++++++++++++++++++ .../projectLibrary/index.vue | 57 ++-- 5 files changed, 324 insertions(+), 19 deletions(-) create mode 100644 jero-web/src/views/projectManagement/projectLibrary/components/changeExtensionModel.vue diff --git a/jero-web/src/common/lang/en-us.js b/jero-web/src/common/lang/en-us.js index 641254c9d..99d08418e 100644 --- a/jero-web/src/common/lang/en-us.js +++ b/jero-web/src/common/lang/en-us.js @@ -1320,4 +1320,5 @@ module.exports = { thereForTheCurrentlySelectedData:'There is no standard breakdown for the currently selected data', secondaryDirectory:'Secondary directory', OnlyPersonsCanBeSelected:'The maximum upper limit is exceeded; Only 100 persons can be selected', + projectVersion:'Project Version', } \ No newline at end of file diff --git a/jero-web/src/common/lang/zh-cn.js b/jero-web/src/common/lang/zh-cn.js index ee36dd5cd..ae714d087 100644 --- a/jero-web/src/common/lang/zh-cn.js +++ b/jero-web/src/common/lang/zh-cn.js @@ -1421,4 +1421,5 @@ module.exports = { thereForTheCurrentlySelectedData:'当前所选数据暂无标准分解单', secondaryDirectory:'二级目录', OnlyPersonsCanBeSelected:'超出最大上限;最多只能选择100个人员', + projectVersion:'项目版本', } \ No newline at end of file diff --git a/jero-web/src/views/projectManagement/components/addModel.vue b/jero-web/src/views/projectManagement/components/addModel.vue index 30c6324e2..ac2dc5671 100644 --- a/jero-web/src/views/projectManagement/components/addModel.vue +++ b/jero-web/src/views/projectManagement/components/addModel.vue @@ -194,6 +194,20 @@
+ + +
+
+ {{$t('explain')}} +
+ + + +
+
+
@@ -243,6 +257,13 @@ trigger: 'blur' } ], + explain:[ + { + max: 300, + message: this.$t('explain') + this.$t('cannotExceed') + 300 + this.$t('Characters'), + trigger: 'blur' + } + ], attestationPlan: [ { pattern: /(ht|f)tp(s?)\:\/\/[0-9a-zA-Z]([-.\w]*[0-9a-zA-Z])*(:(0-9)*)*(\/?)([a-zA-Z0-9\-\.\?\,\'\/\\\+&%$#_]*)?/, diff --git a/jero-web/src/views/projectManagement/projectLibrary/components/changeExtensionModel.vue b/jero-web/src/views/projectManagement/projectLibrary/components/changeExtensionModel.vue new file mode 100644 index 000000000..645b46d43 --- /dev/null +++ b/jero-web/src/views/projectManagement/projectLibrary/components/changeExtensionModel.vue @@ -0,0 +1,263 @@ + + + + + + + \ No newline at end of file diff --git a/jero-web/src/views/projectManagement/projectLibrary/index.vue b/jero-web/src/views/projectManagement/projectLibrary/index.vue index 89c1b78a8..767b76a02 100644 --- a/jero-web/src/views/projectManagement/projectLibrary/index.vue +++ b/jero-web/src/views/projectManagement/projectLibrary/index.vue @@ -129,6 +129,9 @@ + + {{$t('changeExtension')}} +
+ + + \ No newline at end of file diff --git a/jero-web/src/views/projectManagement/components/versionStatistics.vue b/jero-web/src/views/projectManagement/components/versionStatistics.vue new file mode 100644 index 000000000..a635a771b --- /dev/null +++ b/jero-web/src/views/projectManagement/components/versionStatistics.vue @@ -0,0 +1,211 @@ + + + + + \ No newline at end of file From e9554cfbe214ce3dc182996a85731b70eb59c8c9 Mon Sep 17 00:00:00 2001 From: sunFlower <787203167@qq.com> Date: Mon, 17 Oct 2022 14:51:17 +0800 Subject: [PATCH 079/251] =?UTF-8?q?=E5=B8=83=E5=B1=80=E9=A1=B9=E7=9B=AE?= =?UTF-8?q?=E5=BA=93=E5=8F=98=E6=9B=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/changeExtensionModel.vue | 40 ++++++++++++------- .../projectLibrary/index.vue | 2 +- 2 files changed, 27 insertions(+), 15 deletions(-) diff --git a/jero-web/src/views/projectManagement/projectLibrary/components/changeExtensionModel.vue b/jero-web/src/views/projectManagement/projectLibrary/components/changeExtensionModel.vue index 645b46d43..4702d7eaa 100644 --- a/jero-web/src/views/projectManagement/projectLibrary/components/changeExtensionModel.vue +++ b/jero-web/src/views/projectManagement/projectLibrary/components/changeExtensionModel.vue @@ -70,13 +70,13 @@ trigger: 'blur' } ], - projectVersion:[ + projectVersion: [ { required: true, message: this.$t('projectVersion') + this.$t('cannotEmpty'), trigger: 'blur' } - ], + ] }, disabled: false, projectNameList: [], @@ -98,7 +98,28 @@ }, editModel(value) { this.visible = true - this.formInline = value + this.formInline.id = value.id + if (!value.children) { + this.formInline.projectVersion = '01' + } else if (value.children && value.children.length > 0) { + let projectVersion = value.children[value.children.length - 1].projectVersion + if (projectVersion.slice(0, 1) == '0') { + let num = projectVersion.slice(1, 2) + let numIndex = parseInt(num) + 1 + if (numIndex.length == 1) { + this.formInline.projectVersion = '0' + numIndex + } else { + this.formInline.projectVersion = numIndex + } + } else { + let index = parseInt(projectVersion) + 1 + if (index.length == 1) { + this.formInline.projectVersion = '0' + index + } else { + this.formInline.projectVersion = index + } + } + } this.formInline = { ...this.formInline } this.$nextTick(() => { this.$refs.ruleForm.clearValidate() @@ -110,15 +131,6 @@ handleSubmit() { this.$refs.ruleForm.validate(valid => { if (valid) { - let url = '' - let Action - if (this.formInline.id) { - url = this.url.edit - Action = putAction - } else { - url = this.url.add - Action = postAction - } let query = JSON.parse(JSON.stringify(this.formInline)) Object.keys(query).forEach(res => { if (query[res] && query[res] instanceof Array) { @@ -126,12 +138,12 @@ } }) this.confirmLoading = true - Action(url, query).then((res) => { + postAction('/project/projectLibraryBase/addChild', query).then((res) => { if (res.success) { this.confirmLoading = false this.$message.success(this.$t('OperationSuccessful')) this.visible = false - this.$emit('addModelList') + this.$emit('changeExtensionForm') } else { this.$message.warning(res.message) this.confirmLoading = false diff --git a/jero-web/src/views/projectManagement/projectLibrary/index.vue b/jero-web/src/views/projectManagement/projectLibrary/index.vue index 767b76a02..64b5a9793 100644 --- a/jero-web/src/views/projectManagement/projectLibrary/index.vue +++ b/jero-web/src/views/projectManagement/projectLibrary/index.vue @@ -272,7 +272,7 @@ this.toggleSearchStatus = !this.toggleSearchStatus }, changeExtensionClick(val) { - this.$refs.changeExtensionModelRef.addModel(JSON.parse(JSON.stringify(val))) + this.$refs.changeExtensionModelRef.editModel(JSON.parse(JSON.stringify(val))) }, changeExtensionForm() { From cffd8630a9e9463430c3e48d8abd4f490661ffb3 Mon Sep 17 00:00:00 2001 From: sunFlower <787203167@qq.com> Date: Mon, 17 Oct 2022 14:58:48 +0800 Subject: [PATCH 080/251] =?UTF-8?q?=E5=AF=B9=E6=8E=A5=E9=A1=B9=E7=9B=AE?= =?UTF-8?q?=E5=8F=98=E6=9B=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/changeExtensionModel.vue | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/jero-web/src/views/projectManagement/projectLibrary/components/changeExtensionModel.vue b/jero-web/src/views/projectManagement/projectLibrary/components/changeExtensionModel.vue index 4702d7eaa..cf507de9a 100644 --- a/jero-web/src/views/projectManagement/projectLibrary/components/changeExtensionModel.vue +++ b/jero-web/src/views/projectManagement/projectLibrary/components/changeExtensionModel.vue @@ -99,12 +99,11 @@ editModel(value) { this.visible = true this.formInline.id = value.id - if (!value.children) { + if (!value.versionLast) { this.formInline.projectVersion = '01' - } else if (value.children && value.children.length > 0) { - let projectVersion = value.children[value.children.length - 1].projectVersion - if (projectVersion.slice(0, 1) == '0') { - let num = projectVersion.slice(1, 2) + } else if (value.versionLast) { + if (value.versionLast.slice(0, 1) == '0') { + let num = value.versionLast.slice(1, 2) let numIndex = parseInt(num) + 1 if (numIndex.length == 1) { this.formInline.projectVersion = '0' + numIndex @@ -112,7 +111,7 @@ this.formInline.projectVersion = numIndex } } else { - let index = parseInt(projectVersion) + 1 + let index = parseInt(value.versionLast) + 1 if (index.length == 1) { this.formInline.projectVersion = '0' + index } else { From 308cdf5ffbe126016d73a2f17883195870cb1a2d Mon Sep 17 00:00:00 2001 From: sunFlower <787203167@qq.com> Date: Mon, 17 Oct 2022 16:30:59 +0800 Subject: [PATCH 081/251] =?UTF-8?q?=E5=AF=B9=E6=8E=A5=E9=A1=B9=E7=9B=AE?= =?UTF-8?q?=E5=8F=98=E6=9B=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../views/projectManagement/components/ProjectDetails.vue | 4 ++-- .../src/views/projectManagement/components/addModel.vue | 6 +++--- .../projectLibrary/components/changeExtensionModel.vue | 7 ++++--- 3 files changed, 9 insertions(+), 8 deletions(-) diff --git a/jero-web/src/views/projectManagement/components/ProjectDetails.vue b/jero-web/src/views/projectManagement/components/ProjectDetails.vue index e4b5ccaef..145d068fa 100644 --- a/jero-web/src/views/projectManagement/components/ProjectDetails.vue +++ b/jero-web/src/views/projectManagement/components/ProjectDetails.vue @@ -79,8 +79,8 @@
{{$t('explain')}} - {{queryForm.explain}} + {{queryForm.explanation}}
diff --git a/jero-web/src/views/projectManagement/components/addModel.vue b/jero-web/src/views/projectManagement/components/addModel.vue index ac2dc5671..f5491a55f 100644 --- a/jero-web/src/views/projectManagement/components/addModel.vue +++ b/jero-web/src/views/projectManagement/components/addModel.vue @@ -200,9 +200,9 @@
{{$t('explain')}}
- +
@@ -257,7 +257,7 @@ trigger: 'blur' } ], - explain:[ + explanation:[ { max: 300, message: this.$t('explain') + this.$t('cannotExceed') + 300 + this.$t('Characters'), diff --git a/jero-web/src/views/projectManagement/projectLibrary/components/changeExtensionModel.vue b/jero-web/src/views/projectManagement/projectLibrary/components/changeExtensionModel.vue index cf507de9a..3a5bbeb04 100644 --- a/jero-web/src/views/projectManagement/projectLibrary/components/changeExtensionModel.vue +++ b/jero-web/src/views/projectManagement/projectLibrary/components/changeExtensionModel.vue @@ -32,9 +32,10 @@
{{$t('explain')}}
- +
@@ -63,7 +64,7 @@ visible: false, yearNameDataList: [], rules: { - explain: [ + explanation: [ { max: 300, message: this.$t('explain') + this.$t('cannotExceed') + 300 + this.$t('Characters'), From 88a6ef1ae2876bfa1ce657342e42484c836a1273 Mon Sep 17 00:00:00 2001 From: sunFlower <787203167@qq.com> Date: Mon, 17 Oct 2022 16:31:32 +0800 Subject: [PATCH 082/251] =?UTF-8?q?=E5=AF=B9=E6=8E=A5=E9=A1=B9=E7=9B=AE?= =?UTF-8?q?=E5=8F=98=E6=9B=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- jero-web/src/views/projectManagement/projectLibrary/index.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/jero-web/src/views/projectManagement/projectLibrary/index.vue b/jero-web/src/views/projectManagement/projectLibrary/index.vue index 64b5a9793..40230bc35 100644 --- a/jero-web/src/views/projectManagement/projectLibrary/index.vue +++ b/jero-web/src/views/projectManagement/projectLibrary/index.vue @@ -227,7 +227,7 @@ align: 'center', width: 280, ellipsis: true, - dataIndex: 'explain' + dataIndex: 'explanation' }, // { // title: this.$t('certifiedEngineer'), From 525eab9ff733e4a6718ae614e3147b49aa001c1a Mon Sep 17 00:00:00 2001 From: zhn <947514737@qq.com> Date: Mon, 17 Oct 2022 16:58:33 +0800 Subject: [PATCH 083/251] =?UTF-8?q?=E9=A1=B9=E7=9B=AE=E6=89=A9=E5=B1=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../ProjectLibraryBaseController.java | 14 +++ .../project/entity/ProjectLibraryBase.java | 14 +++ .../service/IProjectLibraryBaseService.java | 8 ++ .../impl/ProjectLibraryBaseServiceImpl.java | 91 ++++++++++++++++++- 4 files changed, 122 insertions(+), 5 deletions(-) diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/controller/ProjectLibraryBaseController.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/controller/ProjectLibraryBaseController.java index 46058eaca..c943984bf 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/controller/ProjectLibraryBaseController.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/controller/ProjectLibraryBaseController.java @@ -77,6 +77,20 @@ public class ProjectLibraryBaseController extends JeroController addChild(@Validated @RequestBody ProjectLibraryBase projectLibraryBase) throws ParseException { + projectLibraryBaseService.addChild(projectLibraryBase); + return Result.OK("添加成功!"); + } /** * 编辑 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 b5eeb4c7e..8fe663fd7 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 @@ -109,4 +109,18 @@ public class ProjectLibraryBase implements Serializable { /**目标市场展示名称*/ @TableField(exist = false) private java.lang.String targetMarketName; + + //主项目id parent_id + private String parentId; + + //排序 + private String projectVersion; + + //最后一个版本 + @TableField(exist = false) + private String versionLast; + + //说明 + private String explanation; + } diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/service/IProjectLibraryBaseService.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/service/IProjectLibraryBaseService.java index f6f29e54c..0168cf5db 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/service/IProjectLibraryBaseService.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/service/IProjectLibraryBaseService.java @@ -26,6 +26,14 @@ public interface IProjectLibraryBaseService extends IService */ void add(ProjectLibraryBase projectLibraryBase) throws ParseException; + /** + * 项目扩展(添加子项目-子项目基本信息、相关人员名单、法规/认证任务计划与被扩展项目保持一致) + * + * @param projectLibraryBase + * @return + */ + void addChild(ProjectLibraryBase projectLibraryBase) throws ParseException; + /** * 更新 * diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/service/impl/ProjectLibraryBaseServiceImpl.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/service/impl/ProjectLibraryBaseServiceImpl.java index 583d26a56..f5a90ed15 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/service/impl/ProjectLibraryBaseServiceImpl.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/service/impl/ProjectLibraryBaseServiceImpl.java @@ -1,6 +1,6 @@ package com.jero.modules.project.service.impl; -import cn.hutool.core.lang.func.Func1; +import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; import com.baomidou.mybatisplus.core.metadata.IPage; import com.baomidou.mybatisplus.extension.plugins.pagination.Page; @@ -11,9 +11,26 @@ import com.jero.common.system.vo.DictModel; import com.jero.common.system.vo.LoginUser; import com.jero.modules.cert.collect.service.IParamsManifestEOService; import com.jero.modules.enums.DictCodeEnum; -import com.jero.modules.project.entity.*; -import com.jero.modules.project.enums.*; -import com.jero.modules.project.mapper.*; +import com.jero.modules.project.entity.ConditionAssessmentEO; +import com.jero.modules.project.entity.ProjectLawsInventoryEO; +import com.jero.modules.project.entity.ProjectLawsInventoryLogEO; +import com.jero.modules.project.entity.ProjectLibraryBase; +import com.jero.modules.project.entity.ProjectLibraryRoleRelEO; +import com.jero.modules.project.entity.ProjectRelatedPersonnel; +import com.jero.modules.project.entity.ProjectTaskInventoryEO; +import com.jero.modules.project.entity.ProjectTaskPlanning; +import com.jero.modules.project.enums.CertificationProgressEnum; +import com.jero.modules.project.enums.CurrentProjectStatusEnum; +import com.jero.modules.project.enums.DesignComplianceStatusEnum; +import com.jero.modules.project.enums.InventoryAffirmStatusEnum; +import com.jero.modules.project.enums.OperatorTypeEnum; +import com.jero.modules.project.enums.ProjectRoleEnum; +import com.jero.modules.project.enums.TaskAffirmStatusEnum; +import com.jero.modules.project.mapper.ProjectLawsInventoryEOMapper; +import com.jero.modules.project.mapper.ProjectLibraryBaseMapper; +import com.jero.modules.project.mapper.ProjectNameInfoEOMapper; +import com.jero.modules.project.mapper.ProjectRelatedPersonnelMapper; +import com.jero.modules.project.mapper.ProjectTaskInventoryEOMapper; import com.jero.modules.project.service.IConditionAssessmentEOService; import com.jero.modules.project.service.IProjectLibraryBaseService; import com.jero.modules.project.service.IProjectLibraryRoleRelEOService; @@ -26,6 +43,7 @@ import com.jero.modules.system.service.ISysDictService; import com.jero.modules.system.service.impl.SysDictItemServiceImpl; import com.jero.modules.system.util.StringUtils; import org.apache.commons.collections4.CollectionUtils; +import org.apache.commons.lang3.ObjectUtils; import org.apache.poi.hssf.usermodel.HSSFSheet; import org.apache.poi.hssf.usermodel.HSSFWorkbook; import org.apache.poi.ss.usermodel.Cell; @@ -33,6 +51,7 @@ import org.apache.poi.ss.usermodel.Row; import org.apache.shiro.SecurityUtils; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; +import org.springframework.transaction.annotation.Propagation; import org.springframework.transaction.annotation.Transactional; import javax.servlet.http.HttpServletRequest; @@ -40,7 +59,13 @@ import javax.servlet.http.HttpServletResponse; import java.io.IOException; import java.io.OutputStream; import java.text.ParseException; -import java.util.*; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.Date; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import java.util.UUID; import java.util.stream.Collectors; /** @@ -131,6 +156,62 @@ public class ProjectLibraryBaseServiceImpl extends ServiceImpl projectRelatedPersonnelList = projectRelatedPersonnelMapper.queryPageList(id, + DictCodeEnum.DUTY_TERRITORY.getValue(), + null, + null, + null, + null); + if(projectRelatedPersonnelList.size() != 0){ + for (ProjectRelatedPersonnel projectRelatedPersonnel : projectRelatedPersonnelList) { + projectRelatedPersonnel.setId(UUID.randomUUID().toString().replace("-", "")); + projectRelatedPersonnel.setProjectId(projectId); + } + projectRelatedPersonnelService.saveBatch(projectRelatedPersonnelList); + } + + //法规/认证任务计划添加数据 projectTaskPlanningService + LambdaQueryWrapper wrapper = new LambdaQueryWrapper<>(); + wrapper.in(ProjectTaskPlanning::getProjectId,projectLibraryBase.getId()); + ProjectTaskPlanning projectTaskPlanning = projectTaskPlanningService.getOne(wrapper); + if(ObjectUtils.isNotEmpty(projectTaskPlanning)){ + projectTaskPlanning.setId(UUID.randomUUID().toString().replace("-", "")); + projectTaskPlanning.setProjectId(projectId); + projectTaskPlanningService.add(projectTaskPlanning); + } + + + //初始化当前项目的studio与项目库 角色关系 projectLibraryRoleRelEOService + LambdaQueryWrapper queryWrapper = new LambdaQueryWrapper<>(); + queryWrapper.in(ProjectLibraryRoleRelEO::getProjectLibraryId,projectLibraryBase.getId()); + ProjectLibraryRoleRelEO projectLibraryRoleRelEO = projectLibraryRoleRelEOService.getOne(queryWrapper); + if(ObjectUtils.isNotEmpty(projectLibraryRoleRelEO)){ + projectLibraryRoleRelEO.setId(UUID.randomUUID().toString().replace("-", "")); + projectLibraryRoleRelEO.setProjectLibraryId(projectId); + projectLibraryRoleRelEOService.add(projectLibraryRoleRelEO); + } + } + /**检查车型名称id,年款号,目标市场同时存在,报错*/ public void checkExitData(ProjectLibraryBase projectLibraryBase){ From 886d4a19611c3294b97ff4c833bae6c1c2fbbb70 Mon Sep 17 00:00:00 2001 From: "zyx.net" Date: Mon, 17 Oct 2022 17:21:39 +0800 Subject: [PATCH 084/251] =?UTF-8?q?=E5=8F=82=E6=95=B0=E9=A1=B9=E6=94=B6?= =?UTF-8?q?=E9=9B=86=E6=B8=85=E5=8D=95=E4=B8=8B=E8=BD=BD=E6=96=87=E4=BB=B6?= =?UTF-8?q?=E5=8E=BB=E9=99=A4=E6=B0=B4=E5=8D=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- jero-web/src/components/CollectionType/index.vue | 6 +++++- .../src/components/uploadFileChangeDown/file.vue | 12 ++++++++++-- 2 files changed, 15 insertions(+), 3 deletions(-) diff --git a/jero-web/src/components/CollectionType/index.vue b/jero-web/src/components/CollectionType/index.vue index 2f8d6386c..2b59628ee 100644 --- a/jero-web/src/components/CollectionType/index.vue +++ b/jero-web/src/components/CollectionType/index.vue @@ -652,7 +652,7 @@
+ :detailDate='detailDate' watermark='download'>
@@ -667,6 +667,10 @@ type: Object, default: {}, require: true + }, + watermark: { + type: String, + default: '' } }, data() { diff --git a/jero-web/src/components/uploadFileChangeDown/file.vue b/jero-web/src/components/uploadFileChangeDown/file.vue index e742821cb..19b236668 100644 --- a/jero-web/src/components/uploadFileChangeDown/file.vue +++ b/jero-web/src/components/uploadFileChangeDown/file.vue @@ -43,7 +43,7 @@ import { mapGetters } from 'vuex' export default { name: 'file', - props: ['disableds', 'thisFileUploadUrl', 'readonly', 'thisFileType', 'isUploadFile', 'detailDate'], + props: ['disableds', 'thisFileUploadUrl', 'readonly', 'thisFileType', 'isUploadFile', 'detailDate','watermark'], data() { return { visible: false, @@ -91,7 +91,11 @@ import { mapGetters } from 'vuex' methods: { ...mapGetters(['userInfo']), download() { - downloadFile('/sys/common/downLoadFile', this.template.templateName, { id: this.template.templateId }) + if(this.watermark == 'download'){ + downloadFile('/sys/common/downLoadFileNOMark', this.template.templateName, { id: this.template.templateId }) + } else { + downloadFile('/sys/common/downLoadFile', this.template.templateName, { id: this.template.templateId }) + } }, perentHandleFunc(data) { this.myfileList = data @@ -220,7 +224,11 @@ import { mapGetters } from 'vuex' // let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + fileQuery.id + fileSuffix) // window.open(url, '_blank') // } else { + if(this.watermark == 'download'){ + downloadFile('/sys/common/downLoadFileNOMark', fileQuery.fileName, { id: fileQuery.id }) + }else { downloadFile('/sys/common/downLoadFile', fileQuery.fileName, { id: fileQuery.id }) + } // } } } From 5a09fefa76f1ab1efbbc450346f4e7181511a173 Mon Sep 17 00:00:00 2001 From: liyawei Date: Mon, 17 Oct 2022 17:22:28 +0800 Subject: [PATCH 085/251] =?UTF-8?q?=E8=AE=A4=E8=AF=81-=E5=8F=82=E6=95=B0?= =?UTF-8?q?=E9=A1=B9=E6=94=B6=E9=9B=86-=E4=B8=8B=E8=BD=BDpdf=E6=97=A0?= =?UTF-8?q?=E6=B0=B4=E5=8D=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../system/controller/CommonController.java | 96 ++++++++++++++++--- 1 file changed, 81 insertions(+), 15 deletions(-) diff --git a/jero-boot/jero-boot-module-system/src/main/java/com/jero/modules/system/controller/CommonController.java b/jero-boot/jero-boot-module-system/src/main/java/com/jero/modules/system/controller/CommonController.java index 6e92fa0dd..d95b68abb 100644 --- a/jero-boot/jero-boot-module-system/src/main/java/com/jero/modules/system/controller/CommonController.java +++ b/jero-boot/jero-boot-module-system/src/main/java/com/jero/modules/system/controller/CommonController.java @@ -7,7 +7,6 @@ import com.jero.common.api.vo.Result; import com.jero.common.constant.enums.CutEnum; import com.jero.common.exception.JeroBootException; import com.jero.common.system.api.ISysBaseAPI; -import com.jero.common.system.vo.LoginUser; import com.jero.common.util.RestUtil; import com.jero.common.util.TokenUtils; import com.jero.common.util.oConvertUtils; @@ -19,7 +18,6 @@ import io.swagger.annotations.Api; import io.swagger.annotations.ApiOperation; import lombok.extern.slf4j.Slf4j; import org.apache.commons.lang3.StringUtils; -import org.apache.shiro.SecurityUtils; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Value; import org.springframework.http.HttpHeaders; @@ -27,12 +25,7 @@ import org.springframework.http.HttpMethod; import org.springframework.http.ResponseEntity; import org.springframework.http.server.ServletServerHttpRequest; import org.springframework.util.AntPathMatcher; -import org.springframework.web.bind.annotation.GetMapping; -import org.springframework.web.bind.annotation.PathVariable; -import org.springframework.web.bind.annotation.PostMapping; -import org.springframework.web.bind.annotation.RequestMapping; -import org.springframework.web.bind.annotation.RequestParam; -import org.springframework.web.bind.annotation.RestController; +import org.springframework.web.bind.annotation.*; import org.springframework.web.multipart.MultipartFile; import org.springframework.web.multipart.MultipartHttpServletRequest; import org.springframework.web.servlet.HandlerMapping; @@ -41,12 +34,7 @@ import org.springframework.web.servlet.ModelAndView; import javax.annotation.Resource; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; -import java.io.BufferedInputStream; -import java.io.File; -import java.io.FileInputStream; -import java.io.IOException; -import java.io.InputStream; -import java.io.OutputStream; +import java.io.*; import java.net.URLDecoder; import java.text.SimpleDateFormat; import java.util.Date; @@ -382,12 +370,13 @@ public class CommonController { fileName = ossFile.getFileName(); response.setContentType("application/force-download");// 设置强制下载不打开 response.addHeader("Content-Disposition", "attachment;fileName=" + new String(fileName.getBytes("UTF-8"),"iso-8859-1")); - InputStream download = CosBootUtil.download(filePath); + File file = new File(filePath); if(file.getName().endsWith(".pdf") || file.getName().endsWith(".PDF")){ SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss"); String currentTime = sdf.format(new Date()); String waterContent = userName+" "+currentTime; + InputStream download = CosBootUtil.download(filePath); newFile = PDFUtils.PDFWatermark(download,uploadpath,file.getName(),waterContent); inputStream = new FileInputStream(newFile.getPath()); }else{ @@ -432,6 +421,83 @@ public class CommonController { } } + /** + * word,excel预览 cos -pdf无水印 + * + * @param id 传入文件id + * @param request + * @param response + */ + @GetMapping(value = "/downLoadFileNOMark") + public void downLoadFileNoPDFWatermarkCos(String id,HttpServletRequest request, HttpServletResponse response,String userName) { + if(StringUtils.isBlank(id)){ + throw new JeroBootException("参数信息不全"); + } + id = id.split("\\.")[0]; + // 查询数据表数据是否存在 + LambdaQueryWrapper queryWrapper = new LambdaQueryWrapper<>(); + queryWrapper.eq(OSSFile::getId,id); + OSSFile ossFile = ossFileService.getOne(queryWrapper); + if( null == ossFile){ + throw new JeroBootException("文件不存在"); + } + InputStream inputStream = null; + OutputStream outputStream = null; + File newFile =null; + try { + String fileName = ""; + //本地下载 + String filePath = ossFile.getUrl(); + if(!CosBootUtil.doesObjectExist(filePath)){ + response.setStatus(404); + throw new RuntimeException("文件不存在.."); + } + // 文件名称 + fileName = ossFile.getFileName(); + response.setContentType("application/force-download");// 设置强制下载不打开 + response.addHeader("Content-Disposition", "attachment;fileName=" + new String(fileName.getBytes("UTF-8"),"iso-8859-1")); + + File file = new File(filePath); + inputStream = CosBootUtil.download(filePath); + outputStream = response.getOutputStream(); + byte[] buf = new byte[1024]; + int len; + while ((len = inputStream.read(buf)) > 0) { + outputStream.write(buf, 0, len); + } + response.flushBuffer(); + } catch (IOException e) { + log.error("文件下载失败" + e.getMessage()); + response.setStatus(404); + e.printStackTrace(); + } finally { + if (inputStream != null) { + try { + inputStream.close(); + } catch (IOException e) { + log.error(e.getMessage(), e); + } + } + if (outputStream != null) { + try { + outputStream.close(); + } catch (IOException e) { + log.error(e.getMessage(), e); + } + + } + if (newFile != null) { + try { + newFile.delete(); + } catch (Exception e) { + log.error(e.getMessage(), e); + } + + } + + } + } + /** * 文件下载 * From 71f2d1f90b58f31faadb29669a9e2d45f2609803 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=AB=98=E5=B5=A9?= Date: Mon, 17 Oct 2022 18:56:54 +0800 Subject: [PATCH 086/251] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E7=94=A8=E6=88=B7?= =?UTF-8?q?=E7=AE=A1=E7=90=86=E6=90=9C=E7=B4=A2=E9=83=A8=E9=97=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../system/controller/SysUserController.java | 24 +++++++++++++++++-- 1 file changed, 22 insertions(+), 2 deletions(-) diff --git a/jero-boot/jero-boot-module-system/src/main/java/com/jero/modules/system/controller/SysUserController.java b/jero-boot/jero-boot-module-system/src/main/java/com/jero/modules/system/controller/SysUserController.java index 4a67f32ad..e4198f9f9 100644 --- a/jero-boot/jero-boot-module-system/src/main/java/com/jero/modules/system/controller/SysUserController.java +++ b/jero-boot/jero-boot-module-system/src/main/java/com/jero/modules/system/controller/SysUserController.java @@ -127,10 +127,24 @@ public class SysUserController { public Result> queryPageList(SysUser user, @RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo, @RequestParam(name = "pageSize", defaultValue = "10") Integer pageSize, HttpServletRequest req) { Result> result = new Result>(); - QueryWrapper queryWrapper = QueryGenerator.initQueryWrapper(user, req.getParameterMap()); + Map reqMap = req.getParameterMap(); + Map newReqMap = new HashMap<>(); + for (String key : reqMap.keySet()){ + if(!key.equals("orgCode")){ + newReqMap.put(key,reqMap.get(key)); + } + } + user.setOrgCode(null); + QueryWrapper queryWrapper = QueryGenerator.initQueryWrapper(user, newReqMap); //TODO 外部模拟登陆临时账号,列表不显示 queryWrapper.ne("username", "_reserve_user_external"); - Page page = new Page(pageNo, pageSize); + String[] orgCode = reqMap.get("orgCode"); + if(null != orgCode && orgCode.length > 0){ + List orgCodeList = sysDepartService.getSubDepIdsByDepId(orgCode[0]); + orgCodeList.add(orgCode[0]); + queryWrapper.in("org_code",orgCodeList); + } + Page page = new Page<>(pageNo, pageSize); IPage pageList = sysUserService.page(page, queryWrapper); //批量查询用户的所属部门 @@ -1549,6 +1563,12 @@ public class SysUserController { for (SysDepartTreeModel sdtm: departTreeModelList) { dutList.addAll(findChildNode(sdtm)); } + SysUser admin = sysUserService.getUserByName("admin"); + DepartUserTree dut = new DepartUserTree(); + dut.setId(admin.getId()); + dut.setName(admin.getUsername()); + dut.setType("User"); + dutList.add(dut); result.setResult(dutList); result.setSuccess(true); return result; From 0a13b9deafdd3293888eec7990a915b8389ac922 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=AB=98=E5=B5=A9?= Date: Mon, 17 Oct 2022 18:57:08 +0800 Subject: [PATCH 087/251] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E7=94=A8=E6=88=B7?= =?UTF-8?q?=E7=AE=A1=E7=90=86=E6=90=9C=E7=B4=A2=E9=83=A8=E9=97=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- jero-boot/db/蔚来标准sql/dev_third_record.sql | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/jero-boot/db/蔚来标准sql/dev_third_record.sql b/jero-boot/db/蔚来标准sql/dev_third_record.sql index 0468e8dc6..a1169539c 100644 --- a/jero-boot/db/蔚来标准sql/dev_third_record.sql +++ b/jero-boot/db/蔚来标准sql/dev_third_record.sql @@ -1179,10 +1179,10 @@ update onl_cgform_field set is_query = '1', is_read_only = '1' where id = '09fa6 -- 配置表,增加问题知识库预览图片配置 2022-09-27 已同步生产环境 INSERT INTO `laws_weilai`.`sys_config` (`id`, `create_by`, `create_time`, `update_by`, `update_time`, `sys_org_code`, `config`, `config_name`) VALUES ('4', 'admin', '2022-09-28 14:35:30', NULL, NULL, 'A01', 'http://grp.nioint.com/', 'domianWebImgURL'); ---问题知识库,增加字段 发布状态 2022-10-13 未同步生产环境 +--问题知识库,增加字段 发布状态 2022-10-13 已同步生产环境 ALTER TABLE `laws_weilai`.`problem_knowledge_base` ADD COLUMN `release_status` varchar(50) NULL COMMENT '发布状态' AFTER `release_time`; ---处理问题知识库数据,发布人,发布时间,发布状态数据sql 2022-10-13 未同步生产环境 +--处理问题知识库数据,发布人,发布时间,发布状态数据sql 2022-10-13 已同步生产环境 update problem_knowledge_base pkd set pkd.release_status = 'Have released',pkd.release_time = pkd.create_time,pkd.release_user_id = (select su.id from sys_user su where su.username = pkd.create_by) From 1f33d84d1a57b13ad6db953d9fbed695d975478e Mon Sep 17 00:00:00 2001 From: zhn <947514737@qq.com> Date: Tue, 18 Oct 2022 09:07:34 +0800 Subject: [PATCH 088/251] =?UTF-8?q?=E9=A1=B9=E7=9B=AE=E5=BA=93--=E5=88=97?= =?UTF-8?q?=E8=A1=A8=E6=9F=A5=E8=AF=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../ProjectLibraryBaseController.java | 17 +++- .../project/entity/ProjectLibraryBase.java | 13 ++- .../mapper/ProjectLibraryBaseMapper.java | 3 +- .../mapper/xml/ProjectLibraryBaseMapper.xml | 68 +++++++++++++- .../service/IProjectLibraryBaseService.java | 7 +- .../impl/ProjectLibraryBaseServiceImpl.java | 88 +++++++++++++++++-- 6 files changed, 178 insertions(+), 18 deletions(-) diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/controller/ProjectLibraryBaseController.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/controller/ProjectLibraryBaseController.java index c943984bf..88a16ebc7 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/controller/ProjectLibraryBaseController.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/controller/ProjectLibraryBaseController.java @@ -1,6 +1,6 @@ package com.jero.modules.project.controller; -import com.baomidou.mybatisplus.core.metadata.IPage; +import com.baomidou.mybatisplus.extension.plugins.pagination.Page; import com.jero.common.api.vo.Result; import com.jero.common.aspect.annotation.AutoLog; import com.jero.common.system.base.controller.JeroController; @@ -12,7 +12,15 @@ import lombok.extern.slf4j.Slf4j; import org.apache.shiro.authz.annotation.RequiresPermissions; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.validation.annotation.Validated; -import org.springframework.web.bind.annotation.*; +import org.springframework.web.bind.annotation.DeleteMapping; +import org.springframework.web.bind.annotation.GetMapping; +import org.springframework.web.bind.annotation.PostMapping; +import org.springframework.web.bind.annotation.PutMapping; +import org.springframework.web.bind.annotation.RequestBody; +import org.springframework.web.bind.annotation.RequestMapping; +import org.springframework.web.bind.annotation.RequestMethod; +import org.springframework.web.bind.annotation.RequestParam; +import org.springframework.web.bind.annotation.RestController; import org.springframework.web.servlet.ModelAndView; import javax.servlet.http.HttpServletRequest; @@ -46,8 +54,9 @@ public class ProjectLibraryBaseController extends JeroController queryPageList(@RequestBody Map params) { - IPage pageList= projectLibraryBaseService.queryPageList(params); - return Result.OK(params.get("cut").toString(),pageList); + List pageList= projectLibraryBaseService.queryPageList(params); + Page pages = projectLibraryBaseService.getPages(Integer.parseInt(params.get("pageNo").toString()), Integer.parseInt(params.get("pageSize").toString()), pageList); + return Result.OK(params.get("cut").toString(),pages); } /** 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 8fe663fd7..eb7f70757 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 @@ -12,7 +12,7 @@ import lombok.EqualsAndHashCode; import lombok.experimental.Accessors; import org.springframework.format.annotation.DateTimeFormat; -import java.io.Serializable; +import java.util.List; /** @@ -25,7 +25,7 @@ import java.io.Serializable; @TableName("project_library_base") @Accessors(chain = true) @EqualsAndHashCode(callSuper = false) -public class ProjectLibraryBase implements Serializable { +public class ProjectLibraryBase implements Comparable { private static final long serialVersionUID = 1L; /**主键*/ @@ -123,4 +123,13 @@ public class ProjectLibraryBase implements Serializable { //说明 private String explanation; + @TableField(exist = false) + private List children; + + @Override + public int compareTo(ProjectLibraryBase o) { + return Integer.valueOf(this.projectVersion)-Integer.valueOf(o.projectVersion);//升序 +// return o.id-this.id;//降序 + } + } diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/mapper/ProjectLibraryBaseMapper.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/mapper/ProjectLibraryBaseMapper.java index 1611566e0..7710ab8fc 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/mapper/ProjectLibraryBaseMapper.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/mapper/ProjectLibraryBaseMapper.java @@ -16,7 +16,8 @@ import java.util.Map; */ public interface ProjectLibraryBaseMapper extends BaseMapper { /**分页列表*/ - IPage queryPageList(IPage page, Map params); + List queryPageList(@Param("params") Map params); +// IPage queryPageList(IPage page, Map params); List getList(@Param("projectLibraryBase") ProjectLibraryBase projectLibraryBase); diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/mapper/xml/ProjectLibraryBaseMapper.xml b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/mapper/xml/ProjectLibraryBaseMapper.xml index ddbfbb6d4..fa9462420 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/mapper/xml/ProjectLibraryBaseMapper.xml +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/mapper/xml/ProjectLibraryBaseMapper.xml @@ -43,7 +43,10 @@ plb.create_time, plb.sys_org_code, plb.update_by, - plb.update_time + plb.update_time, + parent_id, + project_version, + explanation from project_library_base as plb left join project_name_info as pni on plb.project_name_id=pni.id left join sys_user as studiouser on plb.studio_engineer=studiouser.id @@ -113,6 +116,69 @@ order by plb.create_time desc + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/service/IProjectLibraryBaseService.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/service/IProjectLibraryBaseService.java index 76cf8f7ec..8cc1a0e92 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/service/IProjectLibraryBaseService.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/service/IProjectLibraryBaseService.java @@ -102,4 +102,6 @@ public interface IProjectLibraryBaseService extends IService void disposeData(List records,String cut,boolean disposeTargetMarketFlag); Page getPages(Integer currentPage, Integer pageSize, List list); + + void top(String id,String flag); } diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/service/impl/ProjectLibraryBaseServiceImpl.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/service/impl/ProjectLibraryBaseServiceImpl.java index 0f687c9d3..232ebfb7a 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/service/impl/ProjectLibraryBaseServiceImpl.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/service/impl/ProjectLibraryBaseServiceImpl.java @@ -25,6 +25,7 @@ import com.jero.modules.project.enums.InventoryAffirmStatusEnum; import com.jero.modules.project.enums.OperatorTypeEnum; import com.jero.modules.project.enums.ProjectRoleEnum; import com.jero.modules.project.enums.TaskAffirmStatusEnum; +import com.jero.modules.project.enums.TopEnum; import com.jero.modules.project.mapper.ProjectLawsInventoryEOMapper; import com.jero.modules.project.mapper.ProjectLibraryBaseMapper; import com.jero.modules.project.mapper.ProjectNameInfoEOMapper; @@ -570,6 +571,8 @@ public class ProjectLibraryBaseServiceImpl extends ServiceImpl wrapper = new LambdaQueryWrapper<>(); + wrapper.isNotNull(ProjectLibraryBase::getSort).orderByDesc(ProjectLibraryBase::getSort); + List list = this.list(wrapper); + if(list.size() != 0){ + String sort = list.get(list.size() - 1).getSort(); + int sortTemp = Integer.valueOf(sort) + 1; + projectLibraryBase.setSort(String.valueOf(sortTemp)); + }else{ + projectLibraryBase.setSort("1"); + } + projectLibraryBase.setFlag(TopEnum.TOP_CANCEL.getValue()); + } + this.updateById(projectLibraryBase); + } } From 94dad9ec77734e256d178880408fb254bde6fee6 Mon Sep 17 00:00:00 2001 From: sunFlower <787203167@qq.com> Date: Tue, 18 Oct 2022 15:17:03 +0800 Subject: [PATCH 098/251] =?UTF-8?q?=E5=AF=B9=E6=8E=A5=E5=BE=85=E5=8A=9E?= =?UTF-8?q?=E4=B8=AD=E5=BF=83?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- jero-web/src/common/lang/en-us.js | 2 ++ jero-web/src/common/lang/zh-cn.js | 2 ++ .../components/changeExtensionModel.vue | 2 +- .../projectLibrary/index.vue | 27 ++++++++++++++++++- 4 files changed, 31 insertions(+), 2 deletions(-) diff --git a/jero-web/src/common/lang/en-us.js b/jero-web/src/common/lang/en-us.js index 0e8ba619b..bb486614c 100644 --- a/jero-web/src/common/lang/en-us.js +++ b/jero-web/src/common/lang/en-us.js @@ -1324,4 +1324,6 @@ module.exports = { softwareVersion:'Software version', versionStatistics:'Version statistics', addSubproject:'Add Subproject', + Topping:'Topping', + cancelTopping:'Cancel Topping', } \ No newline at end of file diff --git a/jero-web/src/common/lang/zh-cn.js b/jero-web/src/common/lang/zh-cn.js index 2aa54842d..b9960edde 100644 --- a/jero-web/src/common/lang/zh-cn.js +++ b/jero-web/src/common/lang/zh-cn.js @@ -1425,4 +1425,6 @@ module.exports = { softwareVersion:'软件版本', versionStatistics:'版本统计', addSubproject:'添加子项目', + Topping:'置顶', + cancelTopping:'取消置顶', } \ No newline at end of file diff --git a/jero-web/src/views/projectManagement/projectLibrary/components/changeExtensionModel.vue b/jero-web/src/views/projectManagement/projectLibrary/components/changeExtensionModel.vue index a7734d0bd..47ffd5479 100644 --- a/jero-web/src/views/projectManagement/projectLibrary/components/changeExtensionModel.vue +++ b/jero-web/src/views/projectManagement/projectLibrary/components/changeExtensionModel.vue @@ -100,7 +100,7 @@ editModel(value) { this.visible = true this.formInline = {} - this.formInline.id = value.id + this.formInline.id = value.parentId || value.id if (!value.versionLast) { this.formInline.projectVersion = '01' } else if (value.versionLast) { diff --git a/jero-web/src/views/projectManagement/projectLibrary/index.vue b/jero-web/src/views/projectManagement/projectLibrary/index.vue index 27b7cb97b..78717c720 100644 --- a/jero-web/src/views/projectManagement/projectLibrary/index.vue +++ b/jero-web/src/views/projectManagement/projectLibrary/index.vue @@ -129,6 +129,11 @@ + + {{record.flag == '1'?$t('cancelTopping'):$t('Topping')}} + {{$t('addSubproject')}} @@ -254,7 +259,7 @@ title: this.$t('operation'), align: 'center', fixed: 'right', - width: 160, + width: 252, scopedSlots: { customRender: 'operation' } } ], @@ -271,6 +276,26 @@ handleToggleSearch() { this.toggleSearchStatus = !this.toggleSearchStatus }, + toppingClick(row) { + let flag = '' + if (row.flag == '1') { + flag = '0' + } else { + flag = '1' + } + let query = { + flag: flag, + id: row.id + } + getAction('/project/projectLibraryBase/top', query).then((res) => { + if (res.success) { + this.$message.success(this.$t('OperationSuccessful')) + this.getList() + } else { + this.$message.warning(this.$t('operationFailed')) + } + }) + }, changeExtensionClick(val) { this.$refs.changeExtensionModelRef.editModel(JSON.parse(JSON.stringify(val))) }, From 9c94f247bf843c9a838c1c6fcf576a2856ff34b6 Mon Sep 17 00:00:00 2001 From: zhn <947514737@qq.com> Date: Tue, 18 Oct 2022 15:54:14 +0800 Subject: [PATCH 099/251] =?UTF-8?q?=E9=A1=B9=E7=9B=AE=E7=BD=AE=E9=A1=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../mapper/xml/ProjectLibraryBaseMapper.xml | 4 +++- .../impl/ProjectLibraryBaseServiceImpl.java | 16 +++++++++++----- 2 files changed, 14 insertions(+), 6 deletions(-) diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/mapper/xml/ProjectLibraryBaseMapper.xml b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/mapper/xml/ProjectLibraryBaseMapper.xml index ab571bf8d..3fa838a91 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/mapper/xml/ProjectLibraryBaseMapper.xml +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/mapper/xml/ProjectLibraryBaseMapper.xml @@ -47,7 +47,9 @@ plb.parent_id, plb.project_version, plb.explanation, - plb.software_version + plb.software_version, + plb.sort, + plb.flag from project_library_base as plb left join project_name_info as pni on plb.project_name_id=pni.id left join sys_user as studiouser on plb.studio_engineer=studiouser.id diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/service/impl/ProjectLibraryBaseServiceImpl.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/service/impl/ProjectLibraryBaseServiceImpl.java index 232ebfb7a..a359144a4 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/service/impl/ProjectLibraryBaseServiceImpl.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/service/impl/ProjectLibraryBaseServiceImpl.java @@ -2,6 +2,7 @@ package com.jero.modules.project.service.impl; import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; +import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper; import com.baomidou.mybatisplus.extension.plugins.pagination.Page; import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; import com.jero.common.constant.enums.CutEnum; @@ -981,11 +982,8 @@ public class ProjectLibraryBaseServiceImpl extends ServiceImpl wrapper = new LambdaQueryWrapper<>(); wrapper.isNotNull(ProjectLibraryBase::getSort).orderByDesc(ProjectLibraryBase::getSort); @@ -995,11 +993,19 @@ public class ProjectLibraryBaseServiceImpl extends ServiceImpl updateWrapper = new LambdaUpdateWrapper<>(); + updateWrapper.in(ProjectLibraryBase::getId,id); + updateWrapper.set(ProjectLibraryBase::getSort,null).set(ProjectLibraryBase::getFlag,null); + this.update(projectLibraryBase,updateWrapper); } - this.updateById(projectLibraryBase); } } From e955f4b1f7ff63f5b8494516947068e297281870 Mon Sep 17 00:00:00 2001 From: zhn <947514737@qq.com> Date: Tue, 18 Oct 2022 16:07:48 +0800 Subject: [PATCH 100/251] =?UTF-8?q?=E9=A1=B9=E7=9B=AE=E5=BA=93=E8=AF=A6?= =?UTF-8?q?=E6=83=85=E4=B8=AD--=E5=8E=86=E5=8F=B2=E6=95=B0=E6=8D=AE?= =?UTF-8?q?=E4=B8=BB=E7=89=88=E6=9C=AC=E7=9A=84=E9=A1=B9=E7=9B=AE=E7=89=88?= =?UTF-8?q?=E6=9C=AC=E9=BB=98=E8=AE=A400?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../project/service/impl/ProjectLibraryBaseServiceImpl.java | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/service/impl/ProjectLibraryBaseServiceImpl.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/service/impl/ProjectLibraryBaseServiceImpl.java index a359144a4..0db931257 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/service/impl/ProjectLibraryBaseServiceImpl.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/service/impl/ProjectLibraryBaseServiceImpl.java @@ -426,6 +426,10 @@ public class ProjectLibraryBaseServiceImpl extends ServiceImpl targetMarketList = sysDictService.queryDictItemsByCode(DicCodeEnum.REGION.getCode()); for(ProjectLibraryBase projectLibraryBase: records){ + //历史数据的主版本没有版本号,所以默认给00 + if(StringUtils.isBlank(projectLibraryBase.getParentId()) && StringUtils.isBlank(projectLibraryBase.getProjectVersion())){ + projectLibraryBase.setProjectVersion("00"); + } //目标市场 Map param = new HashMap<>(); param.put("cut",cut); From ab92a4dccabcc00deb5bd430137130acdfb3309e Mon Sep 17 00:00:00 2001 From: sunFlower <787203167@qq.com> Date: Wed, 19 Oct 2022 09:40:53 +0800 Subject: [PATCH 101/251] =?UTF-8?q?=E5=AF=B9=E6=8E=A5=E5=BE=85=E5=8A=9E?= =?UTF-8?q?=E4=B8=AD=E5=BF=83?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/listOfRegulations.vue | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) diff --git a/jero-web/src/views/projectManagement/components/listOfRegulations.vue b/jero-web/src/views/projectManagement/components/listOfRegulations.vue index ca9de26a5..c09c6e5c9 100644 --- a/jero-web/src/views/projectManagement/components/listOfRegulations.vue +++ b/jero-web/src/views/projectManagement/components/listOfRegulations.vue @@ -1456,15 +1456,18 @@ this.selectedRowKeys = value }, searchQuery() { + this.selectedRowKeys = [] this.getList() }, searchReset() { this.queryParam = {} + this.selectedRowKeys = [] this.$refs.globalAdvancedQueryRef.resetLine() this.$refs.globalAdvancedQueryRef.emitCallback() // this.getList() }, addModelList() { + this.selectedRowKeys = [] this.getList() }, handleSuperQuery(params, matchType) { @@ -2130,7 +2133,7 @@ } else if (fileSuffix == '.xlsx' || fileSuffix == '.xls') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + fileQuery.id + fileSuffix) window.open(url, '_blank') - }else if(fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg'){ + } else if (fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadImgUrl + '/' + fileQuery.id + fileSuffix) window.open(url, '_blank') } else { @@ -2151,7 +2154,7 @@ } else if (fileSuffix == '.xlsx' || fileSuffix == '.xls') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadFileUrl + '/' + id + fileSuffix) window.open(url, '_blank') - }else if(fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg'){ + } else if (fileSuffix == '.png' || fileSuffix == '.jpeg' || fileSuffix == '.gif' || fileSuffix == '.jpg') { let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + Base64.encode(this.downLoadImgUrl + '/' + id + fileSuffix) window.open(url, '_blank') } else { @@ -2484,17 +2487,17 @@ } ::v-deep .ant-table-body-one { - padding-bottom: 0!important; + padding-bottom: 0 !important; } ::v-deep .antfixedLeft { - padding-bottom: 0!important; - overflow: scroll!important; + padding-bottom: 0 !important; + overflow: scroll !important; } ::v-deep .antfixedRight { - padding-bottom: 0!important; - overflow: scroll!important; + padding-bottom: 0 !important; + overflow: scroll !important; } \ No newline at end of file diff --git a/jero-web/src/views/projectManagement/dialog/ProjectCollectionParameters.vue b/jero-web/src/views/projectManagement/dialog/ProjectCollectionParameters.vue index fa940c45d..d6c03ca68 100644 --- a/jero-web/src/views/projectManagement/dialog/ProjectCollectionParameters.vue +++ b/jero-web/src/views/projectManagement/dialog/ProjectCollectionParameters.vue @@ -10,29 +10,80 @@ :wrapper-col='wrapperCol' > - - - - + +
+
+ * + {{$t('title')}} +
+ + + +
- + +
+
+ {{$t('relatedProjectVersion')}} +
+ + + + + + {{ item }} + + + + +
- +
+ + +
+
+ {{$t('explain')}} +
+ + + +
- - - - + +
+
+ {{$t('entryName')}} +
+ + + +
- - - + + + + + + + + {{ $t('query') }} {{ $t('reset') }} @@ -48,7 +99,7 @@ :dataSource='areaTable' :pagination='false' :loading='loading' - :scroll='{x: 600}' + :scroll='{x: 600,y:400}' :rowSelection='{selectedRowKeys: selectedRowKeys, onChange: onSelectChange}' @change='handleTableChange'> @@ -60,7 +111,7 @@ -
+
- +
\ No newline at end of file From 13308fdb039dea3e231fdc158255713c563f9ff5 Mon Sep 17 00:00:00 2001 From: sunFlower <787203167@qq.com> Date: Thu, 20 Oct 2022 11:10:41 +0800 Subject: [PATCH 114/251] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E8=AE=A4=E8=AF=81?= =?UTF-8?q?=E5=8F=82=E6=95=B0=E5=88=97=E8=A1=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../parameter/parameterlist/components/addModel.vue | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/jero-web/src/views/parameter/parameterlist/components/addModel.vue b/jero-web/src/views/parameter/parameterlist/components/addModel.vue index 5eb433eda..2af0965a4 100644 --- a/jero-web/src/views/parameter/parameterlist/components/addModel.vue +++ b/jero-web/src/views/parameter/parameterlist/components/addModel.vue @@ -225,6 +225,7 @@ @@ -600,9 +601,12 @@ export default { }; }) - - - + }, + onInput(r) { + let value = r.target.value + r.target.value = value.replace(/[!!#]/g, '') + this.formInline.controlValues = r.target.value + this.formInline = {...this.formInline} }, getSysCategoryTree() { getAction('/sys/category/getSysCategoryTree', {}).then((res) => { From 2a6c57e570ed62fbcf6fc19cb86933531e645ce4 Mon Sep 17 00:00:00 2001 From: sunFlower <787203167@qq.com> Date: Thu, 20 Oct 2022 11:25:21 +0800 Subject: [PATCH 115/251] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E8=AE=A4=E8=AF=81?= =?UTF-8?q?=E5=8F=82=E6=95=B0=E5=88=97=E8=A1=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../dialog/ParameterTemplateAdd.vue | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/jero-web/src/views/projectManagement/dialog/ParameterTemplateAdd.vue b/jero-web/src/views/projectManagement/dialog/ParameterTemplateAdd.vue index f8818d1c4..6e8b589cf 100644 --- a/jero-web/src/views/projectManagement/dialog/ParameterTemplateAdd.vue +++ b/jero-web/src/views/projectManagement/dialog/ParameterTemplateAdd.vue @@ -323,14 +323,15 @@ }, editData(edit) { // 编辑一行的数据 - if (edit.projectVersion) { - edit.projectVersion = edit.projectVersion.split(',') + let query = JSON.parse(JSON.stringify(edit)) + if (query.projectVersion) { + query.projectVersion = query.projectVersion.split(',') }else{ - edit.projectVersion = [] + query.projectVersion = [] } - this.row = edit - this.formData = { ...edit } - this.selectedRowKeys = edit.paramsTemplateId.split(',') + this.row = query + this.formData = { ...query } + this.selectedRowKeys = query.paramsTemplateId.split(',') }, //新增 handleSubmit() { From d51e4fe80b068dce186c95f0cec41d74567f38a0 Mon Sep 17 00:00:00 2001 From: zhn <947514737@qq.com> Date: Thu, 20 Oct 2022 11:29:32 +0800 Subject: [PATCH 116/251] =?UTF-8?q?=E7=9B=B8=E5=85=B3=E9=A1=B9=E7=9B=AE?= =?UTF-8?q?=E7=89=88=E6=9C=AC=E6=8E=92=E5=BA=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../project/service/impl/ProjectLibraryBaseServiceImpl.java | 1 + 1 file changed, 1 insertion(+) diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/service/impl/ProjectLibraryBaseServiceImpl.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/service/impl/ProjectLibraryBaseServiceImpl.java index 3acb77e41..39ecfdd40 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/service/impl/ProjectLibraryBaseServiceImpl.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/service/impl/ProjectLibraryBaseServiceImpl.java @@ -1020,6 +1020,7 @@ public class ProjectLibraryBaseServiceImpl extends ServiceImpl result = new ArrayList<>(); if(list.size() != 0){ result = list.stream().map(ProjectLibraryBase::getProjectVersion).collect(Collectors.toList()); + Collections.sort(result); } return result; } From 42ac31df37bb51bf4594c6b70603a929721a289c Mon Sep 17 00:00:00 2001 From: "zyx.net" Date: Thu, 20 Oct 2022 11:44:03 +0800 Subject: [PATCH 117/251] =?UTF-8?q?=E5=8F=82=E6=95=B0=E9=A1=B9=E6=B8=85?= =?UTF-8?q?=E5=8D=95=E8=A1=A8=E5=A4=B4=E6=B7=BB=E5=8A=A0=E4=BC=A0=E5=8F=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- jero-web/src/components/tableCollection/index.vue | 7 +++++-- .../components/ParameterItemCollectionList.vue | 1 + 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/jero-web/src/components/tableCollection/index.vue b/jero-web/src/components/tableCollection/index.vue index 78bc0e00e..3169043da 100644 --- a/jero-web/src/components/tableCollection/index.vue +++ b/jero-web/src/components/tableCollection/index.vue @@ -604,9 +604,11 @@ res.result.userType = result[0] ? result[0].value : '' } this.getTableList(res.result.userType) + this.getHeader(res.result.userType) } else { this.getTableList(result[0].value) + this.getHeader(result[0].value) } this.$emit('LoginUserType', result, this.currentPersonRole, res.result.userType) } else { @@ -614,7 +616,7 @@ } }) }, - getHeader() { + getHeader(userType) { let paramsManifestid let url if (this.$route.query.it === undefined) { @@ -628,7 +630,8 @@ } let params = { paramsManifestId: paramsManifestid, - flag: '7' + flag: '7', + userType:userType, } getAction(url, params).then((res) => { if (res.success) { diff --git a/jero-web/src/views/projectManagement/components/ParameterItemCollectionList.vue b/jero-web/src/views/projectManagement/components/ParameterItemCollectionList.vue index 904a21025..1fb2a099e 100644 --- a/jero-web/src/views/projectManagement/components/ParameterItemCollectionList.vue +++ b/jero-web/src/views/projectManagement/components/ParameterItemCollectionList.vue @@ -717,6 +717,7 @@ if (res.success) { this.currentPersonRole = this.formInlineRoleSwitching.roleSwitchingCode this.$message.success(this.$t('OperationSuccessful')) + this.$refs.CollectionTabel.getHeader(this.currentPersonRole) this.visibleRoleSwitching = false this.confirmLoadingRoleSwitching = false localStorage.setItem('currentPersonRole', JSON.stringify(this.formInlineRoleSwitching.roleSwitchingCode)) From 0b1a9b2df058255906216214effe894f681ad80b Mon Sep 17 00:00:00 2001 From: liyawei Date: Fri, 21 Oct 2022 01:13:23 +0800 Subject: [PATCH 118/251] =?UTF-8?q?=E8=AE=A4=E8=AF=81-=E5=8F=82=E6=95=B0?= =?UTF-8?q?=E9=A1=B9=E6=94=B6=E9=9B=86-=E6=B7=BB=E5=8A=A0=E5=90=8C?= =?UTF-8?q?=E6=AD=A5=E4=B8=8A=E6=8A=A5=E5=BA=93=E6=97=B6=E9=97=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- jero-boot/db/蔚来标准sql/dev_third_record.sql | 7 +++++++ .../controller/ParamsCollectManifestEOController.java | 3 ++- .../cert/collect/entity/ParamsCollectManifestEO.java | 9 +++++++++ .../collect/entity/ParamsCollectManifestHistoryEO.java | 9 +++++++++ .../collect/mapper/xml/ParamsCollectManifestEOMapper.xml | 1 + .../mapper/xml/ParamsCollectManifestHistoryEOMapper.xml | 1 + .../collect/service/IParamsCollectManifestEOService.java | 2 +- .../service/impl/ParamsCollectManifestEOServiceImpl.java | 9 +++++++-- .../impl/ParamsCollectManifestHistoryEOServiceImpl.java | 2 +- 9 files changed, 38 insertions(+), 5 deletions(-) diff --git a/jero-boot/db/蔚来标准sql/dev_third_record.sql b/jero-boot/db/蔚来标准sql/dev_third_record.sql index a1169539c..d5ec0a12e 100644 --- a/jero-boot/db/蔚来标准sql/dev_third_record.sql +++ b/jero-boot/db/蔚来标准sql/dev_third_record.sql @@ -1186,3 +1186,10 @@ ALTER TABLE `laws_weilai`.`problem_knowledge_base` --处理问题知识库数据,发布人,发布时间,发布状态数据sql 2022-10-13 已同步生产环境 update problem_knowledge_base pkd set pkd.release_status = 'Have released',pkd.release_time = pkd.create_time,pkd.release_user_id = (select su.id from sys_user su where su.username = pkd.create_by) +-- 参数项收集清单 添加同步上报库时间字段 2022-10-20 未同步生产环境 +ALTER TABLE `laws_weilai`.`params_collect_manifest` + ADD COLUMN `report_time` datetime NULL COMMENT '同步上报库时间' AFTER `title_default_value`; +ALTER TABLE `laws_weilai`.`params_collect_manifest_history` + ADD COLUMN `report_time` datetime NULL COMMENT '同步上报库时间' AFTER `title_default_value`; + +INSERT INTO `laws_weilai`.`onl_cgform_field`(`id`, `cgform_head_id`, `db_field_name`, `db_field_en_name`, `db_field_txt`, `order_num`, `db_field_name_old`, `db_is_key`, `db_is_null`, `db_type`, `db_length`, `db_point_length`, `db_default_val`, `dict_field`, `dict_table`, `dict_text`, `field_show_type`, `field_href`, `field_length`, `field_valid_type`, `field_must_input`, `field_extend_json`, `field_default_value`, `is_query`, `is_show_form`, `is_show_list`, `is_read_only`, `query_mode`, `main_table`, `main_field`, `update_by`, `update_time`, `create_time`, `create_by`, `converter`, `query_def_val`, `query_dict_text`, `query_dict_field`, `query_dict_table`, `query_show_type`, `query_config_flag`, `query_valid_type`, `query_must_input`, `sort_flag`, `show_area`, `is_show_laws_list`, `is_show_search`, `is_delete`, `is_model`, `dict_id`) VALUES ('5afe057bed3412bcedf5bf17565d3ff4', '9ca1773d2a484d2fadae38491ad51aa1', 'report_time', 'Sync Time', '同步上报库时间', 28, NULL, 0, 1, 'Date', 0, 0, '', '', '', '', 'date', '', 120, NULL, '0', '', '', 0, 0, 1, 0, 'single', '', '', NULL, NULL, '2022-10-20 11:08:04', 'admin', '', '', '', '', '', 'text', '0', NULL, NULL, '0', NULL, NULL, NULL, 0, '7', NULL); diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/cert/collect/controller/ParamsCollectManifestEOController.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/cert/collect/controller/ParamsCollectManifestEOController.java index 349d8ced7..b9da4fa4e 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/cert/collect/controller/ParamsCollectManifestEOController.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/cert/collect/controller/ParamsCollectManifestEOController.java @@ -56,8 +56,9 @@ public class ParamsCollectManifestEOController extends JeroController>> getHeader(@RequestParam(name = "paramsManifestId") String paramsManifestId, @RequestParam(name = "flag") String flag, + @RequestParam(name = "userType", required = false) String userType, @RequestParam(name = "cut") String cut) { - List> list = paramsCollectManifestEOService.getHeader(paramsManifestId, flag, cut); + List> list = paramsCollectManifestEOService.getHeader(paramsManifestId, flag, userType, cut); return Result.OK(list); } diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/cert/collect/entity/ParamsCollectManifestEO.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/cert/collect/entity/ParamsCollectManifestEO.java index 6b38ec36e..2dfe8f17f 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/cert/collect/entity/ParamsCollectManifestEO.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/cert/collect/entity/ParamsCollectManifestEO.java @@ -2,14 +2,17 @@ package com.jero.modules.cert.collect.entity; import com.baomidou.mybatisplus.annotation.TableField; import com.baomidou.mybatisplus.annotation.TableName; +import com.fasterxml.jackson.annotation.JsonFormat; import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import lombok.Data; import lombok.EqualsAndHashCode; import lombok.experimental.Accessors; import org.jeecgframework.poi.excel.annotation.Excel; +import org.springframework.format.annotation.DateTimeFormat; import java.io.Serializable; +import java.util.Date; /** @@ -41,6 +44,12 @@ public class ParamsCollectManifestEO extends ParamsCollectManifestBaseEO impleme @ApiModelProperty(value = "添加标识") private String addFlag; + /**同步上报库时间*/ + @JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd") + @DateTimeFormat(pattern="yyyy-MM-dd") + @ApiModelProperty(value = "同步上报库时间") + private Date reportTime; + @TableField(exist = false) private String userTypes; diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/cert/collect/entity/ParamsCollectManifestHistoryEO.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/cert/collect/entity/ParamsCollectManifestHistoryEO.java index 223acf2b3..7a69ce97f 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/cert/collect/entity/ParamsCollectManifestHistoryEO.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/cert/collect/entity/ParamsCollectManifestHistoryEO.java @@ -1,12 +1,16 @@ package com.jero.modules.cert.collect.entity; import com.baomidou.mybatisplus.annotation.TableName; +import com.fasterxml.jackson.annotation.JsonFormat; import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; import lombok.Data; import lombok.EqualsAndHashCode; import lombok.experimental.Accessors; +import org.springframework.format.annotation.DateTimeFormat; import java.io.Serializable; +import java.util.Date; /** @@ -22,4 +26,9 @@ import java.io.Serializable; @ApiModel(value="params_collect_manifest_history对象", description="参数项收集清单历史版本") public class ParamsCollectManifestHistoryEO extends ParamsCollectManifestBaseEO implements Serializable { + /**同步上报库时间*/ + @JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd") + @DateTimeFormat(pattern="yyyy-MM-dd") + @ApiModelProperty(value = "同步上报库时间") + private Date reportTime; } diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/cert/collect/mapper/xml/ParamsCollectManifestEOMapper.xml b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/cert/collect/mapper/xml/ParamsCollectManifestEOMapper.xml index 9a10df792..26f0ae6c0 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/cert/collect/mapper/xml/ParamsCollectManifestEOMapper.xml +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/cert/collect/mapper/xml/ParamsCollectManifestEOMapper.xml @@ -30,6 +30,7 @@ + diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/cert/collect/mapper/xml/ParamsCollectManifestHistoryEOMapper.xml b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/cert/collect/mapper/xml/ParamsCollectManifestHistoryEOMapper.xml index 07a93e805..e02a6edb6 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/cert/collect/mapper/xml/ParamsCollectManifestHistoryEOMapper.xml +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/cert/collect/mapper/xml/ParamsCollectManifestHistoryEOMapper.xml @@ -27,6 +27,7 @@ + diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/cert/collect/service/IParamsCollectManifestEOService.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/cert/collect/service/IParamsCollectManifestEOService.java index 8904cd11c..16249bc07 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/cert/collect/service/IParamsCollectManifestEOService.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/cert/collect/service/IParamsCollectManifestEOService.java @@ -83,7 +83,7 @@ public interface IParamsCollectManifestEOService extends IService> getHeader(String paramsManifestId, String flag, String cut); + List> getHeader(String paramsManifestId, String flag, String userType, String cut); /** * 提交 diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/cert/collect/service/impl/ParamsCollectManifestEOServiceImpl.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/cert/collect/service/impl/ParamsCollectManifestEOServiceImpl.java index 6ffb1fdef..34349bfc1 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/cert/collect/service/impl/ParamsCollectManifestEOServiceImpl.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/cert/collect/service/impl/ParamsCollectManifestEOServiceImpl.java @@ -749,7 +749,7 @@ public class ParamsCollectManifestEOServiceImpl extends ServiceImpl> getHeader(String paramsManifestId, String flag, String cut) { + public List> getHeader(String paramsManifestId, String flag, String userType, String cut) { List fieldList = onlCgformFieldService.getFieldList(flag); // flag--->7 if (fieldList.size() != 0) { //过滤列表字段(is_show_list-->列表是否显示0否 1是) @@ -772,6 +772,10 @@ public class ParamsCollectManifestEOServiceImpl extends ServiceImpl map = new HashMap<>(); String dbFieldName = onlCgformField.getDbFieldName(); + if ("report_time".equals(dbFieldName) + && (CollectManifestUserTypeEnum.SDT.getValue().equals(userType) || CollectManifestUserTypeEnum.DRE.getValue().equals(userType))) { + continue; + } if ("nio_number".equals(dbFieldName) || "params_name".equals(dbFieldName)) { map.put("click5", true); if("nio_number".equals(dbFieldName)) { @@ -2080,6 +2084,7 @@ public class ParamsCollectManifestEOServiceImpl extends ServiceImpl Date: Fri, 21 Oct 2022 14:05:26 +0800 Subject: [PATCH 119/251] =?UTF-8?q?=E6=B3=95=E8=A7=84=E6=9C=88=E6=8A=A5?= =?UTF-8?q?=E5=A1=AB=E5=86=99--=E4=BF=AE=E6=94=B9=E4=B8=BB=E8=A6=81?= =?UTF-8?q?=E5=86=85=E5=AE=B9=E5=AD=97=E6=AE=B5=E9=95=BF=E5=BA=A6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- jero-boot/db/蔚来标准sql/dev_third_record.sql | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/jero-boot/db/蔚来标准sql/dev_third_record.sql b/jero-boot/db/蔚来标准sql/dev_third_record.sql index d5ec0a12e..43c4a2f47 100644 --- a/jero-boot/db/蔚来标准sql/dev_third_record.sql +++ b/jero-boot/db/蔚来标准sql/dev_third_record.sql @@ -1193,3 +1193,8 @@ ALTER TABLE `laws_weilai`.`params_collect_manifest_history` ADD COLUMN `report_time` datetime NULL COMMENT '同步上报库时间' AFTER `title_default_value`; INSERT INTO `laws_weilai`.`onl_cgform_field`(`id`, `cgform_head_id`, `db_field_name`, `db_field_en_name`, `db_field_txt`, `order_num`, `db_field_name_old`, `db_is_key`, `db_is_null`, `db_type`, `db_length`, `db_point_length`, `db_default_val`, `dict_field`, `dict_table`, `dict_text`, `field_show_type`, `field_href`, `field_length`, `field_valid_type`, `field_must_input`, `field_extend_json`, `field_default_value`, `is_query`, `is_show_form`, `is_show_list`, `is_read_only`, `query_mode`, `main_table`, `main_field`, `update_by`, `update_time`, `create_time`, `create_by`, `converter`, `query_def_val`, `query_dict_text`, `query_dict_field`, `query_dict_table`, `query_show_type`, `query_config_flag`, `query_valid_type`, `query_must_input`, `sort_flag`, `show_area`, `is_show_laws_list`, `is_show_search`, `is_delete`, `is_model`, `dict_id`) VALUES ('5afe057bed3412bcedf5bf17565d3ff4', '9ca1773d2a484d2fadae38491ad51aa1', 'report_time', 'Sync Time', '同步上报库时间', 28, NULL, 0, 1, 'Date', 0, 0, '', '', '', '', 'date', '', 120, NULL, '0', '', '', 0, 0, 1, 0, 'single', '', '', NULL, NULL, '2022-10-20 11:08:04', 'admin', '', '', '', '', '', 'text', '0', NULL, NULL, '0', NULL, NULL, NULL, 0, '7', NULL); + +--法规月报填写修改主要内容中英文字段长度 2022-10-21 未同步生产环境 +ALTER TABLE `laws_weilai`.`laws_monthly_report_write` +MODIFY COLUMN `content_cn` text CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL COMMENT '主要内容中文' AFTER `production_car_implement_time`, +MODIFY COLUMN `content_en` text CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL COMMENT '主要内容英文' AFTER `content_cn`; From 01ce49b7ee41608abe5a4c46a08cbf5912d6985f Mon Sep 17 00:00:00 2001 From: sunFlower <787203167@qq.com> Date: Fri, 21 Oct 2022 15:58:41 +0800 Subject: [PATCH 120/251] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E6=B3=95=E8=A7=84?= =?UTF-8?q?=E6=9C=88=E6=8A=A5=E7=9A=84=E5=AD=97=E7=AC=A6=E9=95=BF=E5=BA=A6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/modules/defaultTemplate.vue | 16 ++++++++-------- .../components/modules/industryTemplate.vue | 8 ++++---- 2 files changed, 12 insertions(+), 12 deletions(-) diff --git a/jero-web/src/views/businessSupport/regulationReport/components/modules/defaultTemplate.vue b/jero-web/src/views/businessSupport/regulationReport/components/modules/defaultTemplate.vue index 77c7b37cf..4797f1267 100644 --- a/jero-web/src/views/businessSupport/regulationReport/components/modules/defaultTemplate.vue +++ b/jero-web/src/views/businessSupport/regulationReport/components/modules/defaultTemplate.vue @@ -366,15 +366,15 @@ ], workProgressEn: [ { - max: 300, - message: this.$t('workProgressEn') + this.$t('cannotExceed') + 300 + this.$t('Characters'), + max: 5000, + message: this.$t('workProgressEn') + this.$t('cannotExceed') + 5000 + this.$t('Characters'), trigger: 'blur' } ], workProgressCn: [ { - max: 300, - message: this.$t('workProgressEn') + this.$t('cannotExceed') + 300 + this.$t('Characters'), + max: 5000, + message: this.$t('workProgressEn') + this.$t('cannotExceed') + 5000 + this.$t('Characters'), trigger: 'blur' } ], @@ -385,8 +385,8 @@ trigger: 'blur' }, { - max: 300, - message: this.$t('primaryCoverageEn') + this.$t('cannotExceed') + 300 + this.$t('Characters'), + max: 5000, + message: this.$t('primaryCoverageEn') + this.$t('cannotExceed') + 5000 + this.$t('Characters'), trigger: 'blur' } ], @@ -397,8 +397,8 @@ trigger: 'blur' }, { - max: 300, - message: this.$t('primaryCoverageCn') + this.$t('cannotExceed') + 300 + this.$t('Characters'), + max: 5000, + message: this.$t('primaryCoverageCn') + this.$t('cannotExceed') + 5000 + this.$t('Characters'), trigger: 'blur' } ], diff --git a/jero-web/src/views/businessSupport/regulationReport/components/modules/industryTemplate.vue b/jero-web/src/views/businessSupport/regulationReport/components/modules/industryTemplate.vue index 834a90e1f..8d73e3bbe 100644 --- a/jero-web/src/views/businessSupport/regulationReport/components/modules/industryTemplate.vue +++ b/jero-web/src/views/businessSupport/regulationReport/components/modules/industryTemplate.vue @@ -241,8 +241,8 @@ trigger: 'blur' }, { - max: 300, - message: this.$t('primaryCoverageEn') + this.$t('cannotExceed') + 300 + this.$t('Characters'), + max: 5000, + message: this.$t('primaryCoverageEn') + this.$t('cannotExceed') + 5000 + this.$t('Characters'), trigger: 'blur' } ], @@ -253,8 +253,8 @@ trigger: 'blur' }, { - max: 300, - message: this.$t('primaryCoverageCn') + this.$t('cannotExceed') + 300 + this.$t('Characters'), + max: 5000, + message: this.$t('primaryCoverageCn') + this.$t('cannotExceed') + 5000 + this.$t('Characters'), trigger: 'blur' } ] From d5ce89b410919bfe601514c2cd8205c575b567fa Mon Sep 17 00:00:00 2001 From: zhn <947514737@qq.com> Date: Fri, 21 Oct 2022 16:08:25 +0800 Subject: [PATCH 121/251] =?UTF-8?q?=E9=A1=B9=E7=9B=AE=E5=BA=93--=E9=A1=B9?= =?UTF-8?q?=E7=9B=AE=E5=90=8D=E7=A7=B0=E6=A8=A1=E7=B3=8A=E6=9F=A5=E8=AF=A2?= =?UTF-8?q?=E7=89=B9=E6=AE=8A=E5=A4=84=E7=90=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../project/mapper/xml/ProjectLibraryBaseMapper.xml | 8 ++++---- .../service/impl/ProjectLibraryBaseServiceImpl.java | 4 ++++ 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/mapper/xml/ProjectLibraryBaseMapper.xml b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/mapper/xml/ProjectLibraryBaseMapper.xml index 3fa838a91..954daa5bf 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/mapper/xml/ProjectLibraryBaseMapper.xml +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/mapper/xml/ProjectLibraryBaseMapper.xml @@ -68,10 +68,10 @@ ( pni.project_name like '%1%%' escape '1' or pni.project_name like '%1%%' escape '1') - (pni.project_name like concat('%',#{params.projectName},'%') or pyni.year_name like concat('%',#{params.projectName},'%')) - - - + + + + diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/service/impl/ProjectLibraryBaseServiceImpl.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/service/impl/ProjectLibraryBaseServiceImpl.java index 39ecfdd40..32943004c 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/service/impl/ProjectLibraryBaseServiceImpl.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/service/impl/ProjectLibraryBaseServiceImpl.java @@ -491,6 +491,10 @@ public class ProjectLibraryBaseServiceImpl extends ServiceImple.getProjectName().toLowerCase().contains(String.valueOf(params.get("projectName")).toLowerCase())).collect(Collectors.toList()); + } //数据组装 List resultTemp = new LinkedList<>(); for (ProjectLibraryBase projectLibraryBase : result) { From 8d94346d829272d02329feb540fe632b5e116c95 Mon Sep 17 00:00:00 2001 From: zhn <947514737@qq.com> Date: Fri, 21 Oct 2022 16:11:40 +0800 Subject: [PATCH 122/251] =?UTF-8?q?=E6=B7=BB=E5=8A=A0SQL(=E6=B3=95?= =?UTF-8?q?=E8=A7=84=E6=9C=88=E6=8A=A5=E5=A1=AB=E5=86=99)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- jero-boot/db/蔚来标准sql/dev_third_record.sql | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/jero-boot/db/蔚来标准sql/dev_third_record.sql b/jero-boot/db/蔚来标准sql/dev_third_record.sql index 43c4a2f47..4fd71c41e 100644 --- a/jero-boot/db/蔚来标准sql/dev_third_record.sql +++ b/jero-boot/db/蔚来标准sql/dev_third_record.sql @@ -1198,3 +1198,8 @@ INSERT INTO `laws_weilai`.`onl_cgform_field`(`id`, `cgform_head_id`, `db_field_n ALTER TABLE `laws_weilai`.`laws_monthly_report_write` MODIFY COLUMN `content_cn` text CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL COMMENT '主要内容中文' AFTER `production_car_implement_time`, MODIFY COLUMN `content_en` text CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL COMMENT '主要内容英文' AFTER `content_cn`; + +--法规月报填写修改NIO工作进展中英文字段长度 2022-10-21 未同步生产环境 +ALTER TABLE `laws_weilai`.`laws_monthly_report_write` +MODIFY COLUMN `work_progress_cn` text CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL COMMENT 'NIO工作进展中文' AFTER `content_en`, +MODIFY COLUMN `work_progress_en` text CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL COMMENT 'NIO工作进展英文' AFTER `work_progress_cn`; From 1e8d18700ba16a1b02a783bdd69420d66f3692ff Mon Sep 17 00:00:00 2001 From: zhn <947514737@qq.com> Date: Fri, 21 Oct 2022 17:22:17 +0800 Subject: [PATCH 123/251] =?UTF-8?q?=E9=A1=B9=E7=9B=AE=E7=8A=B6=E6=80=81--?= =?UTF-8?q?=E7=89=88=E6=9C=AC=E7=BB=9F=E8=AE=A1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../controller/ProjectLibraryBaseController.java | 13 +++++++++++++ .../service/IProjectLibraryBaseService.java | 7 +++++++ .../impl/ProjectLibraryBaseServiceImpl.java | 16 ++++++++++++++++ 3 files changed, 36 insertions(+) diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/controller/ProjectLibraryBaseController.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/controller/ProjectLibraryBaseController.java index 93d455678..6a492db0b 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/controller/ProjectLibraryBaseController.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/controller/ProjectLibraryBaseController.java @@ -255,5 +255,18 @@ public class ProjectLibraryBaseController extends JeroController versionStatistics(String id) { + List projectLibraryBasesList = projectLibraryBaseService.versionStatistics(id); + return Result.OK(projectLibraryBasesList); + } + } diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/service/IProjectLibraryBaseService.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/service/IProjectLibraryBaseService.java index d600f7167..ab619a582 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/service/IProjectLibraryBaseService.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/service/IProjectLibraryBaseService.java @@ -117,4 +117,11 @@ public interface IProjectLibraryBaseService extends IService * @return */ List getVersionsInfo(String id); + + /** + * 版本统计 + * @param id + * @return + */ + List versionStatistics(String id); } diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/service/impl/ProjectLibraryBaseServiceImpl.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/service/impl/ProjectLibraryBaseServiceImpl.java index 32943004c..c6624ebb8 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/service/impl/ProjectLibraryBaseServiceImpl.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/service/impl/ProjectLibraryBaseServiceImpl.java @@ -1028,6 +1028,22 @@ public class ProjectLibraryBaseServiceImpl extends ServiceImpl versionStatistics(String id) { + LambdaUpdateWrapper wrapper = new LambdaUpdateWrapper<>(); + wrapper.in(ProjectLibraryBase::getId,id).or().in(ProjectLibraryBase::getParentId,id); + List list = this.list(wrapper); + if(list.size() != 0){ + Collections.sort(list); + } + return list; + } } From c184964399b2ad45fae8a629d1588fea2c1e5401 Mon Sep 17 00:00:00 2001 From: sunFlower <787203167@qq.com> Date: Fri, 21 Oct 2022 17:30:11 +0800 Subject: [PATCH 124/251] =?UTF-8?q?=E5=AF=B9=E6=8E=A5=E9=A1=B9=E7=9B=AE?= =?UTF-8?q?=E5=BA=93=E5=98=9A=E5=8F=98=E6=9B=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../views/projectManagement/components/projectStatus.vue | 5 +++-- .../projectManagement/components/versionStatistics.vue | 9 +++++---- 2 files changed, 8 insertions(+), 6 deletions(-) diff --git a/jero-web/src/views/projectManagement/components/projectStatus.vue b/jero-web/src/views/projectManagement/components/projectStatus.vue index 311476fba..6e408344b 100644 --- a/jero-web/src/views/projectManagement/components/projectStatus.vue +++ b/jero-web/src/views/projectManagement/components/projectStatus.vue @@ -1,7 +1,8 @@