@@ -18,17 +18,13 @@ var angularApp = angular.module('catapp', ['ui.router','ngTouch','toastr',
1818 'authentication' ,
1919 'factory.appPermission' ,
2020 'appPermission' ,
21- 'dashboard.workzone' ,
22- 'dashboard.help' ,
23- 'dashboard.track' ,
24- 'dashboard.settings' ,
25- 'dashboard.design' ,
21+ 'dashboard' ,
2622 'directive.loading' ,
2723 'ngSanitize' ,
2824 'global.cache' ,
2925 'ui.grid' ,
3026 'ui.grid.pagination' ,
31- 'ui.grid.autoResize' ,
27+ 'ui.grid.autoResize' , 'ui.grid.exporter' ,
3228 'ui.grid.resizeColumns' ,
3329 'global.uiGridOptions' ,
3430 'global.messages'
@@ -87,12 +83,14 @@ angularApp.controller('HeadNavigatorCtrl', ['$scope', '$rootScope', '$http', '$l
8783 workzone : modulePerms . workzoneAccess ( ) ,
8884 design : modulePerms . designAccess ( ) ,
8985 settings : modulePerms . settingsAccess ( ) ,
90- track : modulePerms . trackAccess ( )
86+ track : modulePerms . trackAccess ( ) ,
87+ analyticsBool : modulePerms . analyticsBool ( )
9188 } ;
9289 $rootScope . workZoneBool = _permSet . workzone ;
9390 $rootScope . designBool = _permSet . design ;
9491 $rootScope . settingsBool = _permSet . settings ;
9592 $rootScope . trackBool = _permSet . track ;
93+ $rootScope . analyticsBool = _permSet . analyticsBool ;
9694 } ) ;
9795 $rootScope . $emit ( 'SET_HEADER' , $rootScope . appDetails ) ;
9896 $scope . showLogoutConfirmationSection = false ;
@@ -113,22 +111,4 @@ angularApp.controller('HeadNavigatorCtrl', ['$scope', '$rootScope', '$http', '$l
113111 $rootScope . $on ( 'USER_LOGOUT' , function ( ) {
114112 $scope . doLogout ( ) ;
115113 } ) ;
116- } ] )
117- . controller ( 'dashboardCtrl' , [ '$rootScope' , '$scope' , '$http' , 'uac' , '$location' , '$state' , function ( $rootScope , $scope , $http , uac , $location , $state ) {
118- 'use strict' ;
119- $rootScope . isBreadCrumbAvailable = true ;
120- $rootScope . app . isDashboard = true ;
121- /*State will be dashboard if coming via login flow. So check permission and do default landing logic*/
122- /*Otherwise dont enable default landing logic. This is so that user can land on url directly*/
123- if ( $state . current . name === 'dashboard' ) {
124- if ( $rootScope . workZoneBool ) {
125- $state . go ( 'dashboard.workzone' ) ;
126- } else if ( $rootScope . designBool ) {
127- $state . go ( 'dashboard.design' ) ;
128- } else if ( $rootScope . trackBool ) {
129- $state . go ( 'dashboard.track' ) ;
130- } else if ( $rootScope . settingsBool ) {
131- $state . go ( 'dashboard.settings' ) ;
132- }
133- }
134114} ] ) ;
0 commit comments