Unverified Commit f7577984 authored by mshaik-nisum-com's avatar mshaik-nisum-com Committed by GitHub

Merge pull request #160 from nisum-inc/FEATURE/MT-MENUACTIVESTATE

FEATURE/MT-MENUACTIVESTATE
parents 25e37bd5 cae8bd25
...@@ -8,6 +8,9 @@ myApp.controller("leftmenuController",function($scope, myFactory, $compile){ ...@@ -8,6 +8,9 @@ myApp.controller("leftmenuController",function($scope, myFactory, $compile){
$scope.setTemplateUrl = function(path){ $scope.setTemplateUrl = function(path){
var element = document.getElementById('main'); var element = document.getElementById('main');
path = "'"+path+"'"; path = "'"+path+"'";
var currentEle = event.currentTarget;
$('.navbarMenu').removeClass('activeMenu');
$(currentEle).addClass('activeMenu');  
element.setAttribute("ng-include", path); element.setAttribute("ng-include", path);
var newTemplate = angular.element(element); var newTemplate = angular.element(element);
$('#main').html(newTemplate); $('#main').html(newTemplate);
......
...@@ -225,4 +225,7 @@ md-select { ...@@ -225,4 +225,7 @@ md-select {
} }
.ui-grid-pager-panel{ .ui-grid-pager-panel{
background-color: floralwhite; background-color: floralwhite;
}
.activeMenu{
background-color: #312A25;
} }
\ No newline at end of file
<!-- Sidebar --> <!-- Sidebar -->
<div id="sidebar-wrapper"> <div id="sidebar-wrapper">
<ul class="sidebar-nav col-lg-12 col-md-12 col-sm-12 col-xs-12" > <ul class="sidebar-nav col-lg-12 col-md-12 col-sm-12 col-xs-12" >
<li ng-repeat="menuItem in menuItems"><a href="#" <li ng-repeat="menuItem in menuItems"><a href="#" class="navbarMenu"
ng-click="setTemplateUrl(menuItem.path)"><i ng-click="setTemplateUrl(menuItem.path)"><i
class="{{menuItem.icon}}" style="font-size: 1.5em;" class="{{menuItem.icon}}" style="font-size: 1.5em;"
aria-hidden="false"> </i> <span style="margin-left: 15px;">{{menuItem.menu}}</span></a></li> aria-hidden="false"> </i> <span style="margin-left: 15px;">{{menuItem.menu}}</span></a></li>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment