angular.module('focaBotoneraPrincipal') .controller('focaBotoneraPrincipalController', [ '$scope', '$location', '$localStorage', 'botones', 'focaModalService', 'APP', function($scope, $location, $localStorage, botones, focaModalService, APP) { $scope.paginas = []; if(APP === 'distribuidor') { $scope.paginas.push(botones.data.slice(0, 3)); $scope.paginas.push(botones.data.slice(3, 6)); } else { $scope.paginas.push(botones.data); } $scope.irA = function(accion) { $location.path(accion); }; $scope.logout = function() { $location.path('/logout'); }; $scope.showTerminal = function() { var key = $localStorage.terminalKey; focaModalService.alert('SU TERMINAL ES: ' + key); }; } ]);