Browse Source

git-svn-id: svn+ssh://10.10.101.21/source/platform/platform-b2b@672 f3bf4e98-0cf0-11e4-a00c-a99a8b9d557d

administrator 11 years ago
parent
commit
5384259952
1 changed files with 56 additions and 4 deletions
  1. 56 4
      src/main/webapp/resources/js/index/app.js

+ 56 - 4
src/main/webapp/resources/js/index/app.js

@@ -113,16 +113,48 @@ define([ 'toaster', 'charts', 'ngTable', 'common/services', 'service/Purc', 'ui.
 			url : "/sample",
 			templateUrl : "static/tpl/index/sale/sample.html",
 			controller: 'SaleSampleCtrl'
-		}).state('user', {
-			url : "/user",
+		}).state('account', {
+			url : "/account",
 			views : {
 				"left-view" : {
-					templateUrl : "static/tpl/index/user/left.html"
+					templateUrl : "static/tpl/index/account/left.html"
 				},
 				"right-view" : {
-					templateUrl : "static/tpl/index/user/right.html"
+					templateUrl : "static/tpl/index/account/right.html"
 				}
 			}
+		}).state('account.index', {
+			url : "",
+			templateUrl : "static/tpl/index/account/index.html",
+			controller: function($rootScope) {
+				$rootScope.active = null;
+			}
+		}).state('account.home', {
+			url : "/",
+			templateUrl : "static/tpl/index/account/index.html",
+			controller: function($rootScope) {
+				$rootScope.active = null;
+			}
+		}).state('account.enterprise', {
+			url : "/enterprise",
+			templateUrl : "static/tpl/index/account/enterprise.html",
+			controller: 'EnterpriseCtrl'
+		}).state('account.user', {
+			url : "/user",
+			templateUrl : "static/tpl/index/account/user.html",
+			controller: 'UserCtrl'
+		}).state('account.resource', {
+			url : "/resource",
+			templateUrl : "static/tpl/index/account/resource.html",
+			controller: 'ResourceCtrl'
+		}).state('account.authority', {
+			url : "/authority",
+			templateUrl : "static/tpl/index/account/authority.html",
+			controller: 'AuthorityCtrl'
+		}).state('account.role', {
+			url : "/role",
+			templateUrl : "static/tpl/index/account/role.html",
+			controller: 'RoleCtrl'
 		}).state('qc', {
 			url : "/qc",
 			views : {
@@ -1341,6 +1373,26 @@ define([ 'toaster', 'charts', 'ngTable', 'common/services', 'service/Purc', 'ui.
 		
 	});
 	
+	app.controller('EnterpriseCtrl', function($scope, $rootScope){
+		$rootScope.active = 'enterprise';
+	});
+	
+	app.controller('UserCtrl', function($scope, $rootScope){
+		$rootScope.active = 'user';
+	});
+	
+	app.controller('ResourceCtrl', function($scope, $rootScope){
+		$rootScope.active = 'resource';
+	});
+	
+	app.controller('AuthorityCtrl', function($scope, $rootScope){
+		$rootScope.active = 'authority';
+	});
+	
+	app.controller('RoleCtrl', function($scope, $rootScope){
+		$rootScope.active = 'role';
+	});
+	
 	/**
 	 * 计算时间差
 	 */