Commit 6bc64990 authored by Vladimir Baranov's avatar Vladimir Baranov

FIX, rclose#5480. Fix right panel keeps to be visible

parent 07d73273
...@@ -87,11 +87,11 @@ angular.module('ulakbus.auth') ...@@ -87,11 +87,11 @@ angular.module('ulakbus.auth')
* @returns {*} * @returns {*}
*/ */
authService.logout = function () { authService.logout = function () {
$rootScope.loginAttempt = 0; $rootScope.loginAttempt = 0;
WSOps.request({wf: 'logout'}).then(function (data) { WSOps.request({wf: 'logout'}).then(function (data) {
$rootScope.loggedInUser = false; $rootScope.loggedInUser = false;
$rootScope.current_user = true; $rootScope.current_user = true;
$rootScope.$broadcast("user_logged_out");
$log.debug("loggedout"); $log.debug("loggedout");
$location.path("/login"); $location.path("/login");
WSOps.close(); WSOps.close();
......
...@@ -19,8 +19,8 @@ ...@@ -19,8 +19,8 @@
<div class="dashboard-search-results" ng-show="showResults"> <div class="dashboard-search-results" ng-show="showResults">
<ul ng-if="students.length > 0"> <ul ng-if="students.length > 0">
<li ng-repeat="student in students"> <li ng-repeat="student in students">
<a role="button"> <a role="button" ng-click="select(student, 'ogrenci')">
<span ng-click="select(student, 'ogrenci')">{{student[0]}}</span> <span>{{student[0]}}</span>
<i class="fa fa-fw fa-info-circle pull-right" popover-placement="bottom" <i class="fa fa-fw fa-info-circle pull-right" popover-placement="bottom"
uib-popover-template="userPopover.templateUrl" uib-popover-template="userPopover.templateUrl"
ng-click="get_info('Ogrenci', student[2])"></i></a> ng-click="get_info('Ogrenci', student[2])"></i></a>
...@@ -42,8 +42,8 @@ ...@@ -42,8 +42,8 @@
<div class="dashboard-search-results" ng-show="showResults"> <div class="dashboard-search-results" ng-show="showResults">
<ul ng-if="staffs.length > 0"> <ul ng-if="staffs.length > 0">
<li ng-repeat="staff in staffs"> <li ng-repeat="staff in staffs">
<a role="button"> <a role="button" ng-click="select(staff, 'personel')">
<span ng-click="select(staff, 'personel')">{{staff[0]}}</span> <span>{{staff[0]}}</span>
<i class="fa fa-fw fa-info-circle pull-right" <i class="fa fa-fw fa-info-circle pull-right"
popover-placement="bottom" popover-placement="bottom"
uib-popover-template="userPopover.templateUrl" uib-popover-template="userPopover.templateUrl"
......
...@@ -19,8 +19,8 @@ ...@@ -19,8 +19,8 @@
<div class="dashboard-search-results" ng-show="showResults"> <div class="dashboard-search-results" ng-show="showResults">
<ul ng-if="students.length > 0"> <ul ng-if="students.length > 0">
<li ng-repeat="student in students"> <li ng-repeat="student in students">
<a role="button"> <a role="button" ng-click="select(student, 'ogrenci')">
<span ng-click="select(student, 'ogrenci')">{{student[0]}}</span> <span>{{student[0]}}</span>
<i class="fa fa-fw fa-info-circle pull-right" popover-placement="bottom" <i class="fa fa-fw fa-info-circle pull-right" popover-placement="bottom"
uib-popover-template="userPopover.templateUrl" uib-popover-template="userPopover.templateUrl"
ng-click="get_info('Ogrenci', student[2])"></i></a> ng-click="get_info('Ogrenci', student[2])"></i></a>
...@@ -42,8 +42,8 @@ ...@@ -42,8 +42,8 @@
<div class="dashboard-search-results" ng-show="showResults"> <div class="dashboard-search-results" ng-show="showResults">
<ul ng-if="staffs.length > 0"> <ul ng-if="staffs.length > 0">
<li ng-repeat="staff in staffs"> <li ng-repeat="staff in staffs">
<a role="button"> <a role="button" ng-click="select(staff, 'personel')">
<span ng-click="select(staff, 'personel')">{{staff[0]}}</span> <span>{{staff[0]}}</span>
<i class="fa fa-fw fa-info-circle pull-right" <i class="fa fa-fw fa-info-circle pull-right"
popover-placement="bottom" popover-placement="bottom"
uib-popover-template="userPopover.templateUrl" uib-popover-template="userPopover.templateUrl"
......
...@@ -459,6 +459,9 @@ angular.module('ulakbus') ...@@ -459,6 +459,9 @@ angular.module('ulakbus')
delete $scope.selectedMenuItems; delete $scope.selectedMenuItems;
}; };
// clean selection when user logged out
$rootScope.$on('user_logged_out', $scope.deselectUser);
$rootScope.$watch(function ($rootScope) { $rootScope.$watch(function ($rootScope) {
return $rootScope.section; return $rootScope.section;
}, },
......
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