2
0
Fork 0
tcrud/lib/www_views/node-ff-tcrud/angular/js/application-controller.ejs

18 lines
658 B
Plaintext
Raw Normal View History

2017-06-10 14:53:29 +00:00
'use strict';
tcrudUI.controller('ApplicationController',function($scope,$http,$location,navigationService) {
console.log('start menu controller');
$scope.goLink = function ( path ) {
2017-12-23 21:45:27 +00:00
$location.path( path );
console.log('goto link3: '+path);
return false;
2017-06-10 14:53:29 +00:00
};
$scope.navigationService = navigationService;
$scope.applicationMenu = {};
2017-12-23 21:45:27 +00:00
$http.get('<%= troot.tmeta.tserver.tslugs.tbase %>/<%= troot.tmeta.tserver.tslugs.tserver %>/config/menu').then(function ok(response) {
$scope.applicationMenu = response.data.data;
$scope.applicationMenuKeys = Object.keys(response.data.data);
console.log('Menu keys',$scope.applicationMenuKeys);
2017-06-10 14:53:29 +00:00
});
});