12345678910111213141516171819202122232425262728 |
- /**
- * Created by robin on 11/1/15.
- */
-
- angular.module('app')
- .controller('ToolBarController', ['$scope', '$state', '$mdSidenav', 'DataShareBusiness',
- function($scope, $state, $mdSidenav, DataShareBusiness) {
-
- $scope.DataShareBusiness = DataShareBusiness;
-
- $scope.toggleSideBar = function()
- {
- $mdSidenav('left').toggle();
- };
-
- $scope.isInState = function(state)
- {
- return $state.current.name == state;
- };
-
- $scope.getStateName = function()
- {
- if ($state.current.name.length == 0) {
- return "home";
- }
- return $state.current.name;
- };
- }]);
|