From 930a0652ab5b2e34c8b3b184659f84ae82e8ce25 Mon Sep 17 00:00:00 2001
From: Ldc <ldc@vci.com>
Date: 星期日, 07 四月 2024 18:14:10 +0800
Subject: [PATCH] Merge remote-tracking branch 'origin/master'
---
Source/ProjectWeb/src/router/page/index.js | 12 ++++
Source/platformProject/vci-platform-web/src/main/java/com/vci/web/controller/WebUIDataController.java | 2
Source/platformProject/pom.xml | 18 +++++
Source/ProjectWeb/src/router/avue-router.js | 36 ++++++++----
Source/platformProject/vci-platform-web/src/main/java/com/vci/web/service/impl/UIEngineServiceImpl.java | 27 ++++----
Source/ProjectWeb/src/store/modules/user.js | 20 +++++-
Source/platformProject/vci-platform-server-starter/pom.xml | 1
Source/platformProject/vci-platform-web/pom.xml | 29 +++------
8 files changed, 97 insertions(+), 48 deletions(-)
diff --git a/Source/ProjectWeb/src/router/avue-router.js b/Source/ProjectWeb/src/router/avue-router.js
index a12448f..9d2fc30 100644
--- a/Source/ProjectWeb/src/router/avue-router.js
+++ b/Source/ProjectWeb/src/router/avue-router.js
@@ -97,7 +97,9 @@
// 璁剧疆 props榛樿鍊� 浣滅敤灏辨槸灏嗗瓧娈佃缃垚閰嶇疆鐨�
const propsDefault = {
label: propsConfig.label || 'name',
- path: propsConfig.path || 'path',
+ path:'code',
+ code: 'code',
+ pathValue:'pathValue',
icon: propsConfig.icon || 'icon',
children: propsConfig.children || 'children',
meta: propsConfig.meta || 'meta',
@@ -110,15 +112,25 @@
const oMenu = aMenu[i];
// 杩欎竴鍧楃殑璧嬪�� 涔熷氨鏄彇鍒拌繑鍥炵殑鍊�
let path = (() => {
- if (first) {
- // 灏� '/index' 鏇挎崲涓� ''
- return oMenu[propsDefault.path].replace('/index', '')
- } else {
- return oMenu[propsDefault.path]
- }
- })(),
- //鐗规畩澶勭悊缁勪欢 鎵ц瀹岃繖涓� component 涔熷氨鏄簿纭埌鍏蜂綋鐨勬枃浠朵簡 views鏂囦欢澶逛笅闈㈠氨鏄叿浣撶殑椤甸潰浠g爜
- component = 'views' + path,
+ if (first) {
+ // 灏� '/index' 鏇挎崲涓� ''
+ return oMenu[propsDefault.pathValue].replace('/index', '')
+ } else {
+ return oMenu[propsDefault.pathValue]
+ }
+ })();
+ let code = (() => {
+ return oMenu[propsDefault.code]
+ })();
+ // 灏嗗瓧绗︿覆鍒嗗壊鎴愭暟缁勶紝浠�'?'浣滀负鍒嗛殧绗�
+ let parts = path.split("?");
+ // 濡傛灉鏁扮粍鐨勯暱搴﹀ぇ浜�1锛岃〃绀烘湁'?'锛屽垯鍙栫涓�涓厓绱犵殑绗竴涓儴鍒嗭紝鍚﹀垯鐩存帴鍙栨暣涓瓧绗︿覆
+ let bsValue = parts.length > 1 ? parts[0].split("=")[1] : path.split("=")[1];
+ if (bsValue === '' || bsValue === undefined || bsValue === null) {
+ bsValue = "UI";
+ }
+ //鐗规畩澶勭悊缁勪欢 鎵ц瀹岃繖涓� component 涔熷氨鏄簿纭埌鍏蜂綋鐨勬枃浠朵簡 views鏂囦欢澶逛笅闈㈠氨鏄叿浣撶殑椤甸潰浠g爜
+ let component = bsValue === 'UI' ? 'views/base/UIContentViewer' : `views/custom-ui/${bsValue}`,
name = oMenu[propsDefault.label],
icon = oMenu[propsDefault.icon],
children = oMenu[propsDefault.children],
@@ -134,7 +146,7 @@
//鏄惁鏈夊瓙璺敱
const isChild = children.length !== 0;
const oRouter = {
- path: path,
+ path: '/' + code,
component(resolve) {
// 鍒ゆ柇鏄惁涓洪璺敱
if (first) {
@@ -162,7 +174,7 @@
children: !isChild ? (() => {
if (first) {
// 杩欓噷鐨刬sURL鍒ゆ柇锛屽洜涓鸿繖涓綉绔欐湁浣跨敤 iframe銆傛墍浠ラ渶瑕佸垽鏂槸鍚︿负缃戦〉閾炬帴
- if (!isURL(path)) oMenu[propsDefault.path] = `${path}/index`;
+ if (!isURL(path)) oMenu[propsDefault.pathValue] = `${path}/index`;
return [{
component(resolve) {
require([`../${component}.vue`], resolve)
diff --git a/Source/ProjectWeb/src/router/page/index.js b/Source/ProjectWeb/src/router/page/index.js
index 255d6a9..6172f26 100644
--- a/Source/ProjectWeb/src/router/page/index.js
+++ b/Source/ProjectWeb/src/router/page/index.js
@@ -90,6 +90,18 @@
]
},
{
+ path: '/UIContentViewer',
+ name: '鍔ㄦ�佽〃鏍奸〉闈�',
+ component: Layout,
+ children: [
+ {
+ path: '', // 绌鸿矾寰勮〃绀鸿闂� '/dynamic-form' 鏃跺姞杞� Layout 缁勪欢
+ component: () => import('@/views/base/UIContentViewer'),
+ props: true
+ }
+ ]
+ },
+ {
path: '/referIndex',
name: '鍔ㄦ�佽〃鏍奸〉闈�',
component: Layout,
diff --git a/Source/ProjectWeb/src/store/modules/user.js b/Source/ProjectWeb/src/store/modules/user.js
index 1a65fee..3878f5f 100644
--- a/Source/ProjectWeb/src/store/modules/user.js
+++ b/Source/ProjectWeb/src/store/modules/user.js
@@ -27,10 +27,22 @@
} else {
ele[propsDefault.children].forEach(child => {
addPath(child);
- })
- }
+ });
+ }
}
+
+function updateCode(items) {
+ items.forEach(item => {
+ item.pathValue = item.path;
+ item.path = '/' + item.code;
+ if (item.children && item.children.length > 0) {
+ updateCode(item.children);
+ }
+ });
+}
+
+
const user = {
state: {
@@ -208,10 +220,12 @@
let menu = deepClone(data);
menu.forEach(ele => {
addPath(ele, true);
+ updateCode([ele]);
});
+
commit('SET_MENU_ALL', menu)
commit('SET_MENU', menu)
- //dispatch('GetButtons');
+ //dispatch('GetButtons');s
resolve(menu)
})
})
diff --git a/Source/platformProject/pom.xml b/Source/platformProject/pom.xml
index f740a56..8a37391 100644
--- a/Source/platformProject/pom.xml
+++ b/Source/platformProject/pom.xml
@@ -2,12 +2,15 @@
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+
<modelVersion>4.0.0</modelVersion>
+
<modules>
<module>vci-platform-web</module>
<module>vci-platform-starter</module>
<module>vci-platform-server-starter</module>
</modules>
+
<groupId>com.vci</groupId>
<artifactId>platform-parent</artifactId>
<version>2022.1-SNAPSHOT</version>
@@ -18,7 +21,8 @@
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<java.version>1.8</java.version>
</properties>
- <distributionManagement>
+
+ <!-- <distributionManagement>
<repository>
<id>rdc-releases</id>
<url>http://nexus.vci-tech.com:9000/repository/maven-releases/</url>
@@ -27,7 +31,19 @@
<id>rdc-snapshots</id>
<url>http://nexus.vci-tech.com:9000/repository/maven-snapshots/</url>
</snapshotRepository>
+ </distributionManagement>-->
+ <!-- Maven鍒嗗彂鏋勪欢鐨勪綅缃紝绉佹湇鍦板潃 -->
+ <distributionManagement>
+ <repository>
+ <id>rdc-releases</id>
+ <url>http://dev.yunkeruida.top:9000/repository/maven-releases/</url>
+ </repository>
+ <snapshotRepository>
+ <id>rdc-snapshots</id>
+ <url>http://dev.yunkeruida.top:9000/repository/maven-snapshots/</url>
+ </snapshotRepository>
</distributionManagement>
+
<dependencyManagement>
<dependencies>
<dependency>
diff --git a/Source/platformProject/vci-platform-server-starter/pom.xml b/Source/platformProject/vci-platform-server-starter/pom.xml
index 037d784..697a464 100644
--- a/Source/platformProject/vci-platform-server-starter/pom.xml
+++ b/Source/platformProject/vci-platform-server-starter/pom.xml
@@ -104,7 +104,6 @@
<artifactId>UIService-server</artifactId>
<version>2024.RELEASE</version>
<scope>system</scope>
- <systemPath>D:/work/newplatform/Bin/lib/service/UIService.jar</systemPath>
</dependency>
<dependency><!--UI宸ュ巶锛岄儴鍒唈ar寮曠敤-->
<groupId>com.vci.platform</groupId>
diff --git a/Source/platformProject/vci-platform-web/pom.xml b/Source/platformProject/vci-platform-web/pom.xml
index 11b3900..2923196 100644
--- a/Source/platformProject/vci-platform-web/pom.xml
+++ b/Source/platformProject/vci-platform-web/pom.xml
@@ -11,7 +11,7 @@
<artifactId>vci-platform-web</artifactId>
- <dependencies>
+ <dependencies>
<dependency>
<groupId>com.vci</groupId>
<artifactId>vci-starter-parent</artifactId>
@@ -21,9 +21,7 @@
<dependency>
<groupId>com.vci.corba</groupId>
<artifactId>plt-slice</artifactId>
- <version>1.0</version>
- <scope>system</scope>
- <systemPath>D:/work/newplatform/Bin/lib/common/plt-slice.jar</systemPath>
+ <version>1.0.RELEASE</version>
</dependency>
<dependency>
@@ -154,24 +152,18 @@
<dependency>
<groupId>com.vci.client</groupId>
<artifactId>plt-clientbase</artifactId>
- <version>1.0</version>
- <scope>system</scope>
- <systemPath>D:/work/newplatform/Bin/lib/client/plt-clientbase.jar</systemPath>
+ <version>1.0.RELEASE</version>
</dependency>
<dependency>
<groupId>com.zeroc</groupId>
- <artifactId>icegridgui.jar</artifactId>
- <version>1.0</version>
- <scope>system</scope>
- <systemPath>D:/work/newplatform/Bin/lib/common/icegridgui.jar</systemPath>
+ <artifactId>icegridgui</artifactId>
+ <version>1.0.RELEASE</version>
</dependency>
- <dependency>
- <groupId>com.vci.common</groupId>
- <artifactId>plt-common.jar</artifactId>
- <version>1.0</version>
- <scope>system</scope>
- <systemPath>D:/work/newplatform/Bin/lib/common/plt-common.jar</systemPath>
- </dependency>
+ <dependency>
+ <groupId>com.vci.common</groupId>
+ <artifactId>plt-common</artifactId>
+ <version>1.0.RELEASE</version>
+ </dependency>
<dependency>
<groupId>com.vci</groupId>
<artifactId>vci-platform-starter</artifactId>
@@ -250,4 +242,5 @@
</plugins>
</build>
+
</project>
\ No newline at end of file
diff --git a/Source/platformProject/vci-platform-web/src/main/java/com/vci/web/controller/WebUIDataController.java b/Source/platformProject/vci-platform-web/src/main/java/com/vci/web/controller/WebUIDataController.java
index 9e8b57d..3d9b040 100644
--- a/Source/platformProject/vci-platform-web/src/main/java/com/vci/web/controller/WebUIDataController.java
+++ b/Source/platformProject/vci-platform-web/src/main/java/com/vci/web/controller/WebUIDataController.java
@@ -1,5 +1,6 @@
package com.vci.web.controller;
+import com.vci.starter.web.annotation.controller.VciUnCheckRight;
import com.vci.starter.web.annotation.log.VciBusinessLog;
import com.vci.starter.web.pagemodel.*;
import com.vci.web.dto.*;
@@ -64,6 +65,7 @@
* @return 鏍戠殑鏁版嵁
*/
@PostMapping("/getDataForTree")
+ @VciUnCheckRight
@VciBusinessLog(operateName = "鏍戠殑鏌ヨ",description = "${param.btmname}")
public List<Tree> getDataForTree(UITreeQuery treeQuery){
return uiDataService.getDataForTree(treeQuery);
diff --git a/Source/platformProject/vci-platform-web/src/main/java/com/vci/web/service/impl/UIEngineServiceImpl.java b/Source/platformProject/vci-platform-web/src/main/java/com/vci/web/service/impl/UIEngineServiceImpl.java
index 7543aad..4bfe77d 100644
--- a/Source/platformProject/vci-platform-web/src/main/java/com/vci/web/service/impl/UIEngineServiceImpl.java
+++ b/Source/platformProject/vci-platform-web/src/main/java/com/vci/web/service/impl/UIEngineServiceImpl.java
@@ -1194,19 +1194,20 @@
if(StringUtils.isBlank(componentOid)){
return null;
}
-// if(!QUERY_BY_CACHE){
-// try {
-// return uiComponentDO2VO(platformClientUtil.getPortalService().getPLPageDefinationById(componentOid),true);
-// } catch (VCIError vciError) {
-// throw WebUtil.getVciBaseException(vciError);
-// }
-// }else{
-// List<UIComponentVO> componentVOS = self.selectAllUIComponent();
-// List<UIComponentVO> componentVOList = Optional.ofNullable(componentVOS).orElseGet(() -> new ArrayList<>()).stream().filter(s -> s.getOid().equalsIgnoreCase(componentOid)).collect(Collectors.toList());
-// if(!CollectionUtils.isEmpty(componentVOList)){
-// return componentVOList.get(0);
-// }
-// }
+ if(!QUERY_BY_CACHE){
+ try {
+ platformClientUtil.getPortalService().getPLPageDefinationById(componentOid);
+ return uiComponentDO2VO(null,true);
+ } catch (VCIError vciError) {
+ throw WebUtil.getVciBaseException(vciError);
+ }
+ }else{
+ List<UIComponentVO> componentVOS = self.selectAllUIComponent();
+ List<UIComponentVO> componentVOList = Optional.ofNullable(componentVOS).orElseGet(() -> new ArrayList<>()).stream().filter(s -> s.getOid().equalsIgnoreCase(componentOid)).collect(Collectors.toList());
+ if(!CollectionUtils.isEmpty(componentVOList)){
+ return componentVOList.get(0);
+ }
+ }
return null;
}
--
Gitblit v1.9.3