mirror of
https://github.com/gyurix1968/guacamole-client.git
synced 2025-09-10 07:01:21 +00:00
GUAC-1126 Created user page service which provides the list of main pages for a user.
This commit is contained in:
committed by
Michael Jumper
parent
1d0b32388b
commit
7bf4cb83d8
@@ -30,9 +30,11 @@ angular.module('home').controller('homeController', ['$scope', '$injector',
|
||||
var ConnectionGroup = $injector.get("ConnectionGroup");
|
||||
|
||||
// Get required services
|
||||
var $location = $injector.get("$location");
|
||||
var authenticationService = $injector.get("authenticationService");
|
||||
var connectionGroupService = $injector.get("connectionGroupService");
|
||||
var permissionService = $injector.get("permissionService");
|
||||
var userPageService = $injector.get("userPageService");
|
||||
|
||||
/**
|
||||
* The root connection group, or null if the connection group hierarchy has
|
||||
@@ -67,7 +69,13 @@ angular.module('home').controller('homeController', ['$scope', '$injector',
|
||||
// Retrieve root group and all descendants
|
||||
connectionGroupService.getConnectionGroupTree(ConnectionGroup.ROOT_IDENTIFIER)
|
||||
.success(function rootGroupRetrieved(rootConnectionGroup) {
|
||||
|
||||
$scope.rootConnectionGroup = rootConnectionGroup;
|
||||
|
||||
// Navigate to home page, if not already there
|
||||
var homePage = userPageService.getHomePage(rootConnectionGroup);
|
||||
$location.url(homePage.url);
|
||||
|
||||
});
|
||||
|
||||
// Retrieve current permissions
|
||||
|
Reference in New Issue
Block a user