Selaa lähdekoodia

Merge branch 'master' of https://git.agilestar.cn/spfm-group/spfm-market-front

noob 3 vuotta sitten
vanhempi
commit
a031ebfed9
1 muutettua tiedostoa jossa 40 lisäystä ja 17 poistoa
  1. 40 17
      src/pages/main/leader/processInitiation.vue

+ 40 - 17
src/pages/main/leader/processInitiation.vue

@@ -36,7 +36,8 @@
 				boxHeight: {
 					height: "auto",
 				},
-                outsideModules: [],
+        outsideModules: [],
+          groupName:"",
 			};
 		},
 		methods: {
@@ -52,6 +53,7 @@
 				}).then((res) => {
 					this.funcData = res.data.lineList;
 					this.outsideModules = res.data.outsideModules;
+          this.groupName = res.data.groupName;
 				});
 			},
 			hAuto() {
@@ -65,24 +67,45 @@
 			},
 			jumpTo(v) {
 				if (v.moduleUrl) {
-				    //加入外部人员权限控制start
-                    if (this.outsideModules.length > 0) {
-                        let moduleIndex = -1;
-                        for (let i = 0; i < this.outsideModules.length; i++) {
-                            if(this.outsideModules[i].moduleUrl == v.moduleUrl){
-                                moduleIndex = i;
-                                break;
-                            }
-                        }
-                        if (moduleIndex < 0) {
-                            global.$vm.$notify.error({
-                                title: "提示",
-                                message: "暂无使用权限",
-                            });
-                            return;
+            if(this.groupName == 'default'){
+                //加入外部人员权限控制start
+                if (this.outsideModules.length > 0) {
+                    let moduleIndex = -1;
+                    for (let i = 0; i < this.outsideModules.length; i++) {
+                        if(this.outsideModules[i].moduleUrl == v.moduleUrl){
+                            moduleIndex = i;
+                            break;
                         }
                     }
-                    //加入外部人员权限控制end
+                    if (moduleIndex < 0) {
+                        global.$vm.$notify.error({
+                            title: "提示",
+                            message: "暂无使用权限",
+                        });
+                        return;
+                    }
+                }
+                //加入外部人员权限控制end
+            }else{
+                let childrenMenus = JSON.parse(window.sessionStorage.childrenMenus);
+                if(childrenMenus != undefined && childrenMenus.length > 0){
+                    let moduleIndex = -1;
+                    for(let a =0;a<childrenMenus.length; a++){
+                      if(childrenMenus[a].jspUrl == v.moduleUrl){
+                          moduleIndex = a;
+                          break;
+                      }
+                    }
+                    if (moduleIndex < 0) {
+                        global.$vm.$notify.error({
+                            title: "提示",
+                            message: "暂无使用权限",
+                        });
+                        return;
+                    }
+                }
+            }
+
 
 					this.$router.push({
 						path: v.moduleUrl,