GUACAMOLE-73: Clear permission cache when saving or updating to force permission reload.

This commit is contained in:
James Muehlner
2016-08-16 21:41:43 -07:00
parent 8564f05ead
commit 32f8d84fde
3 changed files with 24 additions and 0 deletions

View File

@@ -145,6 +145,10 @@ angular.module('rest').factory('connectionGroupService', ['$injector',
.success(function connectionGroupCreated(newConnectionGroup){
connectionGroup.identifier = newConnectionGroup.identifier;
cacheService.connections.removeAll();
// Clear users cache to force reload of permissions for this
// newly created connection group
cacheService.users.removeAll();
});
}
@@ -160,6 +164,10 @@ angular.module('rest').factory('connectionGroupService', ['$injector',
// Clear the cache
.success(function connectionGroupUpdated(){
cacheService.connections.removeAll();
// Clear users cache to force reload of permissions for this
// newly updated connection group
cacheService.users.removeAll();
});
}