1(function () { 2 'use strict'; 3 4 var injectParams = ['$location', '$rootScope', '$http', '$templateCache', '$q', '$document', '$scope', 'shoppingCartModel']; 5 6 shell.$inject = injectParams; 7 8 angular.module('app').controller('shell', shell); 9 10 function shell($location, $rootScope, $http, $templateCache, $q, $document, $scope, shoppingCartModel) { 11 var vm = this; 12 13 vm.busyMessage = 'Please wait ...'; 14 vm.isBusy = true; 15 vm.appReady = false; 16 vm.getInfo = false; 17 vm.shoppingCartModel = shoppingCartModel; 18 vm.cartReady = ''; 19 20 idstc().getTranslationsFromServer('general'); 21 22 function capitalizeFirstLetter(string) { 23 return string.charAt(0).toUpperCase() + string.slice(1); 24 } 25 26 //adds notificaiton functions to the supplied object (likely the vm or $scope) 27 //ex. vm.showSuccess('yay', 'title goes here'); 28 (function createNotificationProxy(m) { 29 var notificationTypes = ['success', 'warn', 'error', 'alert']; 30 31 notificationTypes.forEach(function (element, index, array) { 32 33 m['show' + capitalizeFirstLetter(element)] = function (message, title) { 34 idstc().notify({ message: message, title: title, success: element }); 35 } 36 }); 37 })(vm); 38 39 vm.init = function () { 40 // Use promises to wait for all data before displaying form 41 42 var promises = []; 43 44 $q.all(promises).then(function () { 45 vm.appReady = true; 46 }); 47 48 } 49 50 vm.init(); 51 52 $scope.$on('$locationChangeStart', 53 function (event, next, current) { 54 //var nextPath = $location.path(); 55 //if (nextPath == '/checkout') { } 56 } 57 ); 58 59 }; 60 61})();
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.