Commit dfb39bf3 by yangfangfang

同上

parent c7992241
...@@ -181,37 +181,6 @@ ...@@ -181,37 +181,6 @@
$scope.$broadcast("conentresize",true); $scope.$broadcast("conentresize",true);
} }
//flag:1一级菜单显示权限 2:编辑权限
$rootScope.hasTheMenu = function(name,flag,getmenus){
var menus = $rootScope.curRoleAuth.roleAuthDetailList.filter(function(item){
if(angular.isDefined(flag) && flag == 1){
if($rootScope.isweb){
return item.parentAuth == name && $scope.webHideMenus.indexOf(item.auth)==-1;
}
else{
return item.parentAuth == name;
}
}
if(angular.isDefined(flag) && flag == 2){
return item.auth == name && item.edit == true;
}
else{
if(name == 'export'){
return $rootScope.hasTheMenu(name,1);
}
else{
return item.auth == name && item.view == true;
}
}
});
if(angular.isDefined(getmenus)){
return menus;
}
else{
return menus.length>0;
}
}
$rootScope.showSubMenus = function(mainMenu){ $rootScope.showSubMenus = function(mainMenu){
if($scope.channelAlert){ if($scope.channelAlert){
return false; return false;
...@@ -245,13 +214,6 @@ ...@@ -245,13 +214,6 @@
} }
if($rootScope.isSuper || $rootScope.isManage || $rootScope.isAppManage){ if($rootScope.isSuper || $rootScope.isManage || $rootScope.isAppManage){
return true; return true;
}else{
if($rootScope.curRoleAuth){
return $scope.hasTheMenu(name,flag);
}
else{
return false;
}
} }
} }
$rootScope.hasEditPower = function(){ $rootScope.hasEditPower = function(){
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment