You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@guacamole.apache.org by mj...@apache.org on 2018/03/03 20:23:27 UTC
[1/5] guacamole-client git commit: GUACAMOLE-508: Style and comment
fix-ups.
Repository: guacamole-client
Updated Branches:
refs/heads/master 06459629b -> e5a0224ac
GUACAMOLE-508: Style and comment fix-ups.
Project: http://git-wip-us.apache.org/repos/asf/guacamole-client/repo
Commit: http://git-wip-us.apache.org/repos/asf/guacamole-client/commit/4869968c
Tree: http://git-wip-us.apache.org/repos/asf/guacamole-client/tree/4869968c
Diff: http://git-wip-us.apache.org/repos/asf/guacamole-client/diff/4869968c
Branch: refs/heads/master
Commit: 4869968c8f28c0dea5c5b8225908f8d2cc9916f9
Parents: b95b113
Author: Nick Couchman <vn...@apache.org>
Authored: Fri Mar 2 21:35:55 2018 -0500
Committer: Nick Couchman <vn...@apache.org>
Committed: Fri Mar 2 21:45:43 2018 -0500
----------------------------------------------------------------------
.../webapp/app/navigation/services/userPageService.js | 10 +++++++++-
1 file changed, 9 insertions(+), 1 deletion(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/guacamole-client/blob/4869968c/guacamole/src/main/webapp/app/navigation/services/userPageService.js
----------------------------------------------------------------------
diff --git a/guacamole/src/main/webapp/app/navigation/services/userPageService.js b/guacamole/src/main/webapp/app/navigation/services/userPageService.js
index aff16b5..6100237 100644
--- a/guacamole/src/main/webapp/app/navigation/services/userPageService.js
+++ b/guacamole/src/main/webapp/app/navigation/services/userPageService.js
@@ -57,14 +57,22 @@ angular.module('navigation').factory('userPageService', ['$injector',
* A map of all root connection groups visible to the current user,
* where each key is the identifier of the corresponding data source.
*
+ * @param {Object.<String, PermissionSet>} permissions
+ * A map of all permissions granted to the current user, where each
+ * key is the identifier of the corresponding data source.
+ *
+ * @param {Object.<String,
+ *
* @returns {PageDefinition}
* The user's home page.
*/
- var generateHomePage = function generateHomePage(rootGroups,permissions) {
+ var generateHomePage = function generateHomePage(rootGroups, permissions) {
var homePage = null;
var settingsPages = generateSettingsPages(permissions);
+ // If we have more than one setting page, return the main home page
+ // and don't worry about checking for a single connection.
if (settingsPages.length > 1)
return SYSTEM_HOME_PAGE;
[5/5] guacamole-client git commit: GUACAMOLE-508: Merge changes which
take the user to the system home page if they have administrative access.
Posted by mj...@apache.org.
GUACAMOLE-508: Merge changes which take the user to the system home page if they have administrative access.
Project: http://git-wip-us.apache.org/repos/asf/guacamole-client/repo
Commit: http://git-wip-us.apache.org/repos/asf/guacamole-client/commit/e5a0224a
Tree: http://git-wip-us.apache.org/repos/asf/guacamole-client/tree/e5a0224a
Diff: http://git-wip-us.apache.org/repos/asf/guacamole-client/diff/e5a0224a
Branch: refs/heads/master
Commit: e5a0224ac767653551ee54f13807aacb9bb4cf99
Parents: 0645962 0111b03
Author: Michael Jumper <mj...@apache.org>
Authored: Sat Mar 3 12:22:13 2018 -0800
Committer: Michael Jumper <mj...@apache.org>
Committed: Sat Mar 3 12:22:13 2018 -0800
----------------------------------------------------------------------
.../app/navigation/services/userPageService.js | 36 ++++++++++++++++----
1 file changed, 29 insertions(+), 7 deletions(-)
----------------------------------------------------------------------
[3/5] guacamole-client git commit: GUACAMOLE-508: Use object instead
of array for multiple promises.
Posted by mj...@apache.org.
GUACAMOLE-508: Use object instead of array for multiple promises.
Project: http://git-wip-us.apache.org/repos/asf/guacamole-client/repo
Commit: http://git-wip-us.apache.org/repos/asf/guacamole-client/commit/8ad579b9
Tree: http://git-wip-us.apache.org/repos/asf/guacamole-client/tree/8ad579b9
Diff: http://git-wip-us.apache.org/repos/asf/guacamole-client/diff/8ad579b9
Branch: refs/heads/master
Commit: 8ad579b90b7f219085f5b66a0643e65351476df6
Parents: 4869968
Author: Nick Couchman <vn...@apache.org>
Authored: Fri Mar 2 21:45:21 2018 -0500
Committer: Nick Couchman <vn...@apache.org>
Committed: Fri Mar 2 21:58:48 2018 -0500
----------------------------------------------------------------------
.../main/webapp/app/navigation/services/userPageService.js | 7 +++++--
1 file changed, 5 insertions(+), 2 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/guacamole-client/blob/8ad579b9/guacamole/src/main/webapp/app/navigation/services/userPageService.js
----------------------------------------------------------------------
diff --git a/guacamole/src/main/webapp/app/navigation/services/userPageService.js b/guacamole/src/main/webapp/app/navigation/services/userPageService.js
index 6100237..b9144a6 100644
--- a/guacamole/src/main/webapp/app/navigation/services/userPageService.js
+++ b/guacamole/src/main/webapp/app/navigation/services/userPageService.js
@@ -163,9 +163,12 @@ angular.module('navigation').factory('userPageService', ['$injector',
authenticationService.getCurrentUsername()
);
- $q.all([getRootGroups,getPermissionSets])
+ $q.all({
+ rootGroups : getRootGroups,
+ permissionsSets : getPermissionSets
+ })
.then(function rootConnectionGroupsPermissionsRetrieved(data) {
- deferred.resolve(generateHomePage(data[0],data[1]));
+ deferred.resolve(generateHomePage(data.rootGroups,data.permissionsSets));
});
return deferred.promise;
[2/5] guacamole-client git commit: GUACAMOLE-508: Take user to home
page when Settings pages are available.
Posted by mj...@apache.org.
GUACAMOLE-508: Take user to home page when Settings pages are available.
Project: http://git-wip-us.apache.org/repos/asf/guacamole-client/repo
Commit: http://git-wip-us.apache.org/repos/asf/guacamole-client/commit/b95b1131
Tree: http://git-wip-us.apache.org/repos/asf/guacamole-client/tree/b95b1131
Diff: http://git-wip-us.apache.org/repos/asf/guacamole-client/diff/b95b1131
Branch: refs/heads/master
Commit: b95b1131b6314ef579be46b2ba23a313c5e1dca2
Parents: 0645962
Author: Nick Couchman <vn...@apache.org>
Authored: Mon Feb 19 09:57:07 2018 -0500
Committer: Nick Couchman <vn...@apache.org>
Committed: Fri Mar 2 21:45:43 2018 -0500
----------------------------------------------------------------------
.../app/navigation/services/userPageService.js | 25 ++++++++++++++------
1 file changed, 18 insertions(+), 7 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/guacamole-client/blob/b95b1131/guacamole/src/main/webapp/app/navigation/services/userPageService.js
----------------------------------------------------------------------
diff --git a/guacamole/src/main/webapp/app/navigation/services/userPageService.js b/guacamole/src/main/webapp/app/navigation/services/userPageService.js
index 479ae1a..aff16b5 100644
--- a/guacamole/src/main/webapp/app/navigation/services/userPageService.js
+++ b/guacamole/src/main/webapp/app/navigation/services/userPageService.js
@@ -60,9 +60,13 @@ angular.module('navigation').factory('userPageService', ['$injector',
* @returns {PageDefinition}
* The user's home page.
*/
- var generateHomePage = function generateHomePage(rootGroups) {
+ var generateHomePage = function generateHomePage(rootGroups,permissions) {
var homePage = null;
+ var settingsPages = generateSettingsPages(permissions);
+
+ if (settingsPages.length > 1)
+ return SYSTEM_HOME_PAGE;
// Determine whether a connection or balancing group should serve as
// the home page
@@ -140,13 +144,20 @@ angular.module('navigation').factory('userPageService', ['$injector',
var deferred = $q.defer();
// Resolve promise using home page derived from root connection groups
- dataSourceService.apply(
+ var getRootGroups = dataSourceService.apply(
connectionGroupService.getConnectionGroupTree,
authenticationService.getAvailableDataSources(),
ConnectionGroup.ROOT_IDENTIFIER
- )
- .then(function rootConnectionGroupsRetrieved(rootGroups) {
- deferred.resolve(generateHomePage(rootGroups));
+ );
+ var getPermissionSets = dataSourceService.apply(
+ permissionService.getPermissions,
+ authenticationService.getAvailableDataSources(),
+ authenticationService.getCurrentUsername()
+ );
+
+ $q.all([getRootGroups,getPermissionSets])
+ .then(function rootConnectionGroupsPermissionsRetrieved(data) {
+ deferred.resolve(generateHomePage(data[0],data[1]));
});
return deferred.promise;
@@ -342,7 +353,7 @@ angular.module('navigation').factory('userPageService', ['$injector',
var pages = [];
// Get home page and settings pages
- var homePage = generateHomePage(rootGroups);
+ var homePage = generateHomePage(rootGroups, permissions);
var settingsPages = generateSettingsPages(permissions);
// Only include the home page in the list of main pages if the user
@@ -417,4 +428,4 @@ angular.module('navigation').factory('userPageService', ['$injector',
return service;
-}]);
\ No newline at end of file
+}]);
[4/5] guacamole-client git commit: GUACAMOLE-508: More comment clean
up.
Posted by mj...@apache.org.
GUACAMOLE-508: More comment clean up.
Project: http://git-wip-us.apache.org/repos/asf/guacamole-client/repo
Commit: http://git-wip-us.apache.org/repos/asf/guacamole-client/commit/0111b031
Tree: http://git-wip-us.apache.org/repos/asf/guacamole-client/tree/0111b031
Diff: http://git-wip-us.apache.org/repos/asf/guacamole-client/diff/0111b031
Branch: refs/heads/master
Commit: 0111b031e8374ddc1a39239aa4d0843f5ccca72d
Parents: 8ad579b
Author: Nick Couchman <vn...@apache.org>
Authored: Sat Mar 3 07:49:54 2018 -0500
Committer: Nick Couchman <vn...@apache.org>
Committed: Sat Mar 3 07:49:54 2018 -0500
----------------------------------------------------------------------
.../main/webapp/app/navigation/services/userPageService.js | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/guacamole-client/blob/0111b031/guacamole/src/main/webapp/app/navigation/services/userPageService.js
----------------------------------------------------------------------
diff --git a/guacamole/src/main/webapp/app/navigation/services/userPageService.js b/guacamole/src/main/webapp/app/navigation/services/userPageService.js
index b9144a6..749564b 100644
--- a/guacamole/src/main/webapp/app/navigation/services/userPageService.js
+++ b/guacamole/src/main/webapp/app/navigation/services/userPageService.js
@@ -61,8 +61,6 @@ angular.module('navigation').factory('userPageService', ['$injector',
* A map of all permissions granted to the current user, where each
* key is the identifier of the corresponding data source.
*
- * @param {Object.<String,
- *
* @returns {PageDefinition}
* The user's home page.
*/
@@ -71,8 +69,10 @@ angular.module('navigation').factory('userPageService', ['$injector',
var homePage = null;
var settingsPages = generateSettingsPages(permissions);
- // If we have more than one setting page, return the main home page
- // and don't worry about checking for a single connection.
+ // If user has access to settings pages, return home page and skip
+ // evaluation for automatic connections. The Preferences page is
+ // a Settings page and is always visible, so we look for more than
+ // one to indicate access to administrative pages.
if (settingsPages.length > 1)
return SYSTEM_HOME_PAGE;