From 8cbdde400135dbd6c719250bf117a4af673bc84e Mon Sep 17 00:00:00 2001 From: guerler Date: Wed, 12 Feb 2020 15:18:18 -0500 Subject: [PATCH 1/9] Add help label to toolbox filters form to clarify options --- lib/galaxy/webapps/galaxy/api/users.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/lib/galaxy/webapps/galaxy/api/users.py b/lib/galaxy/webapps/galaxy/api/users.py index d589e0cfaea..24c2279d3ec 100644 --- a/lib/galaxy/webapps/galaxy/api/users.py +++ b/lib/galaxy/webapps/galaxy/api/users.py @@ -644,7 +644,11 @@ class UserAPIController(BaseAPIController, UsesTagsMixin, CreatesApiKeysMixin, B for name, value in user.preferences.items(): if name in filter_types: saved_values[name] = listify(value, do_strip=True) - inputs = [] + inputs = [{ + 'type': 'hidden', + 'name': 'helptext', + 'label': 'In this section you may enable or disable Toolbox filters. Please contact your admin to configure filters as necessary.' + }] errors = {} factory = FilterFactory(trans.app.toolbox) for filter_type in filter_types: From 106b590cd22291d3da31c613fa9390801fdefc96 Mon Sep 17 00:00:00 2001 From: guerler Date: Wed, 12 Feb 2020 16:07:55 -0500 Subject: [PATCH 2/9] Fix user preference status message parsing and rendering --- .../scripts/components/User/UserPreferences.vue | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/client/galaxy/scripts/components/User/UserPreferences.vue b/client/galaxy/scripts/components/User/UserPreferences.vue index 5d7a3b86730..7a16ece67bc 100644 --- a/client/galaxy/scripts/components/User/UserPreferences.vue +++ b/client/galaxy/scripts/components/User/UserPreferences.vue @@ -1,6 +1,9 @@ - From d7f56015446cb1d6ef22f40e4adcf221641142d6 Mon Sep 17 00:00:00 2001 From: guerler Date: Wed, 12 Feb 2020 18:35:20 -0500 Subject: [PATCH 7/9] Capitalize user preference option labels --- .../components/User/UserPreferencesModel.js | 30 +++++++++---------- 1 file changed, 15 insertions(+), 15 deletions(-) diff --git a/client/galaxy/scripts/components/User/UserPreferencesModel.js b/client/galaxy/scripts/components/User/UserPreferencesModel.js index 3a8ac11ac3e..921cb68563f 100644 --- a/client/galaxy/scripts/components/User/UserPreferencesModel.js +++ b/client/galaxy/scripts/components/User/UserPreferencesModel.js @@ -6,7 +6,7 @@ export const getUserPreferencesModel = () => { const config = Galaxy.config; return { information: { - title: _l("Manage information"), + title: _l("Manage Information"), description: "Edit your email, addresses and custom parameters or change your public name.", url: `api/users/${Galaxy.user.id}/information/inputs`, icon: "fa-user", @@ -14,16 +14,16 @@ export const getUserPreferencesModel = () => { shouldRender: !config.use_remote_user }, password: { - title: _l("Change password"), + title: _l("Change Password"), description: _l("Allows you to change your login credentials."), icon: "fa-unlock-alt", url: `api/users/${Galaxy.user.id}/password/inputs`, - submit_title: "Save password", + submit_title: "Save Password", redirect: "user", shouldRender: !config.use_remote_user }, communication: { - title: _l("Change communication settings"), + title: _l("Change Communication Settings"), description: _l("Enable or disable the communication feature to chat with other users."), url: `api/users/${Galaxy.user.id}/communication/inputs`, icon: "fa-comments-o", @@ -31,55 +31,55 @@ export const getUserPreferencesModel = () => { shouldRender: !!config.enable_communication_server }, permissions: { - title: _l("Set dataset permissions for new histories"), + title: _l("Set Dataset Permissions for new Histories"), description: "Grant others default access to newly created histories. Changes made here will only affect histories created after these settings have been stored.", url: `api/users/${Galaxy.user.id}/permissions/inputs`, icon: "fa-users", - submit_title: "Save permissions", + submit_title: "Save Permissions", redirect: "user" }, make_data_private: { - title: _l("Make all data private"), + title: _l("Make all Data Private"), description: _l("Click here to make all data private."), icon: "fa-lock" }, api_key: { - title: _l("Manage API key"), + title: _l("Manage API Key"), description: _l("Access your current API key or create a new one."), url: `api/users/${Galaxy.user.id}/api_key/inputs`, icon: "fa-key", - submit_title: "Create a new key", + submit_title: "Create a new Key", submit_icon: "fa-check" }, cloud_auth: { title: _l("Manage Cloud Authorization"), description: _l("Add or modify the configuration that grants Galaxy to access your cloud-based resources."), icon: "fa-cloud", - submit_title: "Create a new key", + submit_title: "Create a new Key", submit_icon: "fa-check" }, toolbox_filters: { - title: _l("Manage Toolbox filters"), + title: _l("Manage Toolbox Filters"), description: _l("Customize your Toolbox by displaying or omitting sets of Tools."), url: `api/users/${Galaxy.user.id}/toolbox_filters/inputs`, icon: "fa-filter", - submit_title: "Save filters", + submit_title: "Save Filters", redirect: "user", shouldRender: !!config.has_user_tool_filters }, custom_builds: { - title: _l("Manage custom builds"), + title: _l("Manage Custom Builds"), description: _l("Add or remove custom builds using history datasets."), icon: "fa-cubes" }, genomespace: { - title: _l("Request GenomeSpace token"), + title: _l("Request GenomeSpace Token"), description: _l("Requests token through OpenID."), icon: "fa-openid" }, logout: { - title: _l("Sign out"), + title: _l("Sign Out"), description: _l("Click here to sign out of all sessions."), icon: "fa-sign-out", shouldRender: !!Galaxy.session_csrf_token From d1d8e2f3da64503a0399ca29441b7abee5d4358f Mon Sep 17 00:00:00 2001 From: guerler Date: Wed, 12 Feb 2020 19:05:52 -0500 Subject: [PATCH 8/9] Catch value error in quota editing, parse as action input error instead, fixes quota error handling in admin panel for invalid inputs --- lib/galaxy/actions/admin.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/galaxy/actions/admin.py b/lib/galaxy/actions/admin.py index 3879f6b794e..e6d622bdb6d 100644 --- a/lib/galaxy/actions/admin.py +++ b/lib/galaxy/actions/admin.py @@ -100,7 +100,7 @@ class AdminActions(object): else: try: new_amount = util.size_to_bytes(params.amount) - except AssertionError: + except (AssertionError, ValueError): new_amount = False if not params.amount: raise ActionInputError('Enter a valid amount.') From 1b4d7a20e13e4ae6d038b0bb9a7ab4d151d50c83 Mon Sep 17 00:00:00 2001 From: guerler Date: Wed, 12 Feb 2020 19:28:33 -0500 Subject: [PATCH 9/9] Format client --- client/galaxy/scripts/components/User/UserPreferences.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/client/galaxy/scripts/components/User/UserPreferences.vue b/client/galaxy/scripts/components/User/UserPreferences.vue index d69ef1d299a..f0990310f08 100644 --- a/client/galaxy/scripts/components/User/UserPreferences.vue +++ b/client/galaxy/scripts/components/User/UserPreferences.vue @@ -9,7 +9,7 @@ >.

- +