File manager - Edit - /usr/local/cpanel/whostmgr/docroot/templates/cpanel_customization/index.min.js
Back
(function(){"use strict";define(["lodash","angular","cjt/core","cjt/util/locale","app/constants","cjt/modules","uiBootstrap","cjt/directives/callout","app/services/savedService","app/services/beforeUnloadService","app/views/jupiter/logoController","app/views/jupiter/faviconController","app/views/jupiter/linksController","app/views/jupiter/colorsController","app/views/publicContactController"],(function(_,angular,CJT,LOCALE,CONSTANTS){return function(){angular.module("App",["cjt2.config.whm.configProvider","ngRoute","ui.bootstrap","angular-growl","cjt2.whm","customize.services.savedService","customize.services.beforeUnloadService","customize.views.logoController","customize.views.faviconController","customize.views.linksController","customize.views.colorsController","customize.views.publicContactController"]);var app=require(["cjt/bootstrap","uiBootstrap","app/views/jupiter/logoController","app/views/jupiter/faviconController","app/views/jupiter/linksController","app/views/jupiter/colorsController","app/views/publicContactController","app/services/contactService","app/services/customizeService"],(function(BOOTSTRAP){var app=angular.module("App");app.value("PAGE",PAGE);app.value("firstLoad",{branding:true});app.controller("BaseController",["$rootScope","$scope","$route","$location","growl","growlMessages","$timeout","savedService","customizeService",function($rootScope,$scope,$route,$location,growl,growlMessages,$timeout,savedService,customizeService){CONSTANTS.DEFAULT_THEME=PAGE.data.default_theme;$scope.loading=false;$scope.selectedThemeTabList=[];savedService.registerTabs(CONSTANTS.JUPITER_TAB_ORDER);$rootScope.$on("$routeChangeStart",(function(){if(savedService.needToSave()){$scope.reportNotSaved();event.preventDefault()}$scope.loading=true}));$rootScope.$on("$routeChangeSuccess",(function(){$scope.loading=false}));$rootScope.$on("$routeChangeError",(function(){$scope.loading=false}));$rootScope.$on("onBeforeUnload",(function(e,config){if(savedService.needToSave()){config.prompt=LOCALE.maketext("The current tab has unsaved changes. You should save the changes before you navigate to another tab.");e.preventDefault();return}delete e["returnValue"]}));$scope.selectTab=function(index){var tabInfo=getTabInfo();tabInfo.lastTab=index;var activeIndex=tabInfo.index[index];$scope.activeTab=activeIndex};$scope.goTo=function(path){var tabInfo=getTabInfo();tabInfo.lastTab=path;$scope.selectTab(path);$location.path(path);$scope.selectTab(path);$scope.currentTabName=path};$scope.reportNotSaved=function(){growlMessages.destroyAllMessages();growl.error(LOCALE.maketext("The current tab has unsaved changes. You should save the changes before you navigate to another tab."))};$scope.preventDeselect=function($event){if(!$event||!$event.target){return}var tabName=findTabName(angular.element($event.target));if(savedService.needToSave($scope.currentTabName)){if(tabName!==$scope.currentTabName){$scope.reportNotSaved()}$event.preventDefault()}return};function findTabName(el){var name=el.attr("data-tab-name");if(name){return name}var parent=el.parent();if(parent){return findTabName(parent)}return}$scope.byTheme={jupiter:{order:CONSTANTS.JUPITER_TAB_ORDER,index:CONSTANTS.JUPITER_TAB_INDEX,lastTab:""}};$scope.selectedTheme=CONSTANTS.DEFAULT_THEME;$scope.onThemeSelect=function(){initTab()};function getTabInfo(){return $scope.byTheme[$scope.selectedTheme]}$scope.isTheme=function(themeName){return $scope.selectedTheme===themeName};$scope.isActive=function(tabName){return $scope.activeTab===tabName};$scope.getActiveTab=function(){return $scope.activeTab};$scope.currentTabName="";function initTab(){var tabInfo=getTabInfo();$scope.selectedThemeTabList=customizeService.getThemeTabList(tabInfo);var tabName=tabInfo.lastTab||tabInfo.order[0];$timeout((function(){$scope.goTo(tabName)}))}initTab()}]);app.config(["$routeProvider",function($routeProvider){$routeProvider.when("/logos",{controller:"logoController",templateUrl:CJT.buildFullPath("cpanel_customization/views/jupiter/logo.ptt")});$routeProvider.when("/colors",{controller:"colorsController",templateUrl:CJT.buildFullPath("cpanel_customization/views/jupiter/colors.ptt")});$routeProvider.when("/links",{controller:"linksController",templateUrl:CJT.buildFullPath("cpanel_customization/views/jupiter/links.ptt")});$routeProvider.when("/favicon",{controller:"faviconController",templateUrl:CJT.buildFullPath("cpanel_customization/views/jupiter/favicon.ptt")});$routeProvider.when("/public-contact",{controller:"publicContactController",templateUrl:CJT.buildFullPath("cpanel_customization/views/publicContact.ptt")});$routeProvider.otherwise({redirectTo:"/"+CONSTANTS.DEFAULT_ROUTE})}]);BOOTSTRAP()}));return app}}))})();
| ver. 1.4 |
Github
|
.
| PHP 8.1.34 | Generation time: 0.02 |
proxy
|
phpinfo
|
Settings