Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions client/cat3/Gruntfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,7 @@ module.exports = function(grunt) {
{'catalyst/partials/sections/dashboard/workzone/orchestration/orchestration.css':'src/partials/sections/dashboard/workzone/orchestration/orchestration.scss'},
{'catalyst/partials/sections/dashboard/workzone/application/application.css':'src/partials/sections/dashboard/workzone/application/application.scss'},
{'catalyst/partials/sections/dashboard/analytics/analytics.css':'src/partials/sections/dashboard/analytics/analytics.scss'},
{'catalyst/partials/sections/dashboard/bots/bots.css':'src/partials/sections/dashboard/bots/bots.scss'},
{'catalyst/partials/sections/dashboard/setting/setting.css':'src/partials/sections/dashboard/setting/setting.scss'}
]
}
Expand Down
2 changes: 2 additions & 0 deletions client/cat3/main.html
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,8 @@
<script src="src/partials/sections/dashboard/analytics/controller/costCtrl.js"></script>
<script src="src/partials/sections/dashboard/analytics/controller/capacityCtrl.js"></script>
<script src="src/partials/sections/dashboard/analytics/controller/usageCtrl.js"></script>
<script src="src/partials/sections/dashboard/bots/botsCtrl.js"></script>
<script src="src/partials/sections/dashboard/bots/controller/libraryCtrl.js"></script>
<script src="src/partials/sections/dashboard/design/designCtrl.js"></script>
<script src="src/partials/sections/dashboard/help/helpCtrl.js"></script>
<script src="src/partials/sections/dashboard/setting/organization/organizationCtrl.js"></script>
Expand Down
17 changes: 17 additions & 0 deletions client/cat3/src/clientRoutes.js
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,23 @@ function routeConfig($stateProvider, $urlRouterProvider, $httpProvider, modulePe

}]
}
}).state('dashboard.bots', {
url: "/bots",
templateUrl: "src/partials/sections/dashboard/bots/bots.html",
controller: "botsCtrl as bts",
resolve: {
auth: ["$q", function ($q) {
var deferred = $q.defer();
// instead, go to a different page
if (modulePerms.serviceBool()) {
// everything is fine, proceed
deferred.resolve();
} else {
deferred.reject({redirectTo: 'dashboard'});
}
return deferred.promise;
}]
}
}).state('dashboard.settings', {
url: "/settings",
templateUrl: "src/partials/sections/dashboard/setting/setting.html",
Expand Down
5 changes: 5 additions & 0 deletions client/cat3/src/factory/appPermissionServices.js
Original file line number Diff line number Diff line change
Expand Up @@ -27,5 +27,10 @@
//return uac.hasPermission('track','read','module');
return true;
};
this.serviceBool = function() {
//permission response not available in the api response.
//return uac.hasPermission('track','read','module');
return true;
};
}]);
})(angular);
6 changes: 4 additions & 2 deletions client/cat3/src/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -84,13 +84,15 @@ angularApp.controller('HeadNavigatorCtrl', ['$scope', '$rootScope', '$http', '$l
design: modulePerms.designAccess(),
settings: modulePerms.settingsAccess(),
track: modulePerms.trackAccess(),
analyticsBool: modulePerms.analyticsBool()
analyticsBool: modulePerms.analyticsBool(),
serviceBool: modulePerms.serviceBool()
};
$rootScope.workZoneBool = _permSet.workzone;
$rootScope.designBool = _permSet.design;
$rootScope.settingsBool = _permSet.settings;
$rootScope.trackBool = _permSet.track;
$rootScope.analyticsBool = _permSet.analyticsBool;
$rootScope.serviceBool = _permSet.serviceBool;
});
$rootScope.$emit('SET_HEADER', $rootScope.appDetails);
$scope.showLogoutConfirmationSection = false;
Expand All @@ -111,4 +113,4 @@ angularApp.controller('HeadNavigatorCtrl', ['$scope', '$rootScope', '$http', '$l
$rootScope.$on('USER_LOGOUT', function () {
$scope.doLogout();
});
}]);
}]);
8 changes: 8 additions & 0 deletions client/cat3/src/partials/global.scss
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,7 @@ $imagePath : "../../../../../../cat3/images";
z-index: 10;
transition: all .4s ease 0s;
left: -254px;
height: 100%;

&.show-left-tree {
left: 0px;
Expand All @@ -121,6 +122,7 @@ $imagePath : "../../../../../../cat3/images";
background: linear-gradient(to right, #2c3638 99%, #2c3638 100%);
color: #fff;
overflow-y: auto;
height: 100%;
}

div[data-angular-treeview] {
Expand Down Expand Up @@ -1161,4 +1163,10 @@ option.script {
}
.loading-body{
opacity: 0.4;
}
#bots .control-panel-button {
border-radius: 11px;
padding: 2px 5px;
width: 25px;
height: 25px;
}
38 changes: 14 additions & 24 deletions client/cat3/src/partials/globals/header/headerDashboard.html
Original file line number Diff line number Diff line change
Expand Up @@ -40,10 +40,8 @@
</div>
</li>
<li>
<div id="settings" class="headNavigItem" ng-if='settingsBool' ui-sref-active='activeSection'>
<a href="/private/index.html#ajax/Settings/Dashboard.html">
<i class="fa fa-cog white"></i> SETTINGS
</a>
<div id="service" class="headNavigItem" ng-if="serviceBool" ui-sref='dashboard.bots' ui-sref-active='activeSection'>
<i class="fa fa-area-chart white"></i> BOTS
</div>
</li>
<li class="header-right">
Expand All @@ -53,26 +51,18 @@
{{appDetails.cn | uppercase}}
[{{appDetails.roleId}}]
</div>
<div class="btn-icons dropdown pull-right" title="Menu">
<i class="fa fa-ellipsis-v white dropdown-toggle cursor" data-toggle="dropdown"></i>
<ul class="dropdown-menu">
<li class="cursor">
<span>
<div title="Help">
<a href="https://catalyst.readthedocs.org" target="_blank">
<i class="fa fa-question blue"></i> HELP
</a>
</div>
</span>
</li>
<li class="cursor">
<span>
<div ng-click="logoutConfirmation();" title="Logout">
<i class="fa fa-sign-out blue"></i> LOGOUT
</div>
</span>
</li>
</ul>
<div id="settings" class="headNavigItem" ng-if='settingsBool' ui-sref-active='activeSection'>
<a href="/private/index.html#ajax/Settings/Dashboard.html">
<i class="fa fa-cog white"></i> SETTINGS
</a>
</div>
<div id="help" class="headNavigItem">
<a href="https://catalyst.readthedocs.org" target="_blank">
<i class="fa fa-question white"></i> HELP
</a>
</div>
<div id="logout" ng-click="logoutConfirmation();" class="headNavigItem" title="Logout">
<i class="fa fa-sign-out white"></i>
</div>
</div>
</li>
Expand Down
14 changes: 14 additions & 0 deletions client/cat3/src/partials/sections/dashboard/bots/bots.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
<link rel='stylesheet' href='catalyst/partials/sections/dashboard/analytics/analytics.css'>

<div id="analyticsPage" class='fluid-container'>
<div class='col-xs-12 col-sm-12 col-md-12 col-lg-12 panelLeft no-padding'>
<div ng-include="'src/partials/sections/dashboard/bots/view/botsTreeMenu.html'"></div>
</div>


<div class="panelRight" id="bots">
<div id='rightPanel' class='container-fluid'>
<div ui-view></div>
</div>
</div>
</div>
Loading