UNPKG

unserver-unify

Version:

82 lines 2.53 kB
angular.module('bamboo.comadmin', ['ui.router']).config(['$stateProvider', '$urlRouterProvider', function($stateProvider, $urlRouterProvider) { $stateProvider.state('index.comadmin', { url: "/comadmin", views: { "@index": { templateProvider: function(deviceDetector, $templateFactory) { var url = ''; if (deviceDetector.isMobile() && !deviceDetector.isTablet()) { url = 'app/comadmin/mbl_list.html'; } else { url = 'app/comadmin/list.html'; } return $templateFactory.fromUrl(url); }, } }, ncyBreadcrumb: { label: "Job" }, data: { permissions: { only: ['login'], redirectTo: '403', } } }).state('index.comadmin.records', { url: '/records/:jid', views: { "@index": { templateProvider: function(deviceDetector, $templateFactory) { var url = ''; if (deviceDetector.isMobile() && !deviceDetector.isTablet()) { url = 'app/comadmin/mbl_records.html'; } else { url = 'app/comadmin/records.html'; } return $templateFactory.fromUrl(url); }, } }, ncyBreadcrumb: { label: '{{"Records"|translate}} {{jobtitle}}' }, }).state('index.comadmin.records.evaluate', { url: '/evaluation/:uid/:eid', views: { "@index": { templateProvider: function(deviceDetector, $templateFactory) { var url = ''; if (deviceDetector.isMobile() && !deviceDetector.isTablet()) { url = 'app/comadmin/mbl_evaluation.html'; } else { url = 'app/comadmin/evaluation.html'; } return $templateFactory.fromUrl(url); }, } }, ncyBreadcrumb: { label: '{{"Evaluation"|translate}} {{fullname}}' }, }).state('index.comadmin.records.groupevaluate', { url: '/group/:eid/:gid', views: { "@index": { templateProvider: function(deviceDetector, $templateFactory) { var url = ''; if (deviceDetector.isMobile() && !deviceDetector.isTablet()) { url = 'app/comadmin/mbl_group-evaluation.html'; } else { url = 'app/comadmin/group-evaluation.html'; } return $templateFactory.fromUrl(url); }, } }, ncyBreadcrumb: { label: 'Group Evaluate' }, }); } ]);