diff --git a/client/galaxy/scripts/components/User/UserPreferences.vue b/client/galaxy/scripts/components/User/UserPreferences.vue index 6a294d9fc97..6bc0e467dd5 100644 --- a/client/galaxy/scripts/components/User/UserPreferences.vue +++ b/client/galaxy/scripts/components/User/UserPreferences.vue @@ -1,21 +1,22 @@ - diff --git a/client/galaxy/scripts/components/User/UserPreferencesModel.js b/client/galaxy/scripts/components/User/UserPreferencesModel.js index 5078266abf4..58660c8549e 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,50 +31,50 @@ 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" }, 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 diff --git a/client/galaxy/scripts/entry/analysis/AnalysisRouter.js b/client/galaxy/scripts/entry/analysis/AnalysisRouter.js index b110e99c372..c7bb042d06f 100644 --- a/client/galaxy/scripts/entry/analysis/AnalysisRouter.js +++ b/client/galaxy/scripts/entry/analysis/AnalysisRouter.js @@ -111,10 +111,11 @@ export const getAnalysisRouter = Galaxy => }, show_user: function() { - const UserPreferencesInstance = Vue.extend(UserPreferences); - const vm = document.createElement("div"); - this.page.display(vm); - new UserPreferencesInstance().$mount(vm); + const Galaxy = getGalaxyInstance(); + this._display_vue_helper(UserPreferences, { + enableQuotas: Galaxy.config.enable_quotas, + userId: Galaxy.user.id + }); }, show_user_form: function(form_id) { 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.') 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: diff --git a/lib/galaxy/webapps/galaxy/controllers/history.py b/lib/galaxy/webapps/galaxy/controllers/history.py index d6bfcb4132b..55505610e5d 100644 --- a/lib/galaxy/webapps/galaxy/controllers/history.py +++ b/lib/galaxy/webapps/galaxy/controllers/history.py @@ -29,6 +29,7 @@ from galaxy.util import ( Params, parse_int, sanitize_text, + string_as_bool, unicodify ) from galaxy.web import url_for @@ -456,8 +457,8 @@ class HistoryController(BaseUIController, SharableMixin, UsesAnnotations, UsesIt return trans.fill_template_mako( "history/as_xml.mako", history=history, - show_deleted=galaxy.util.string_as_bool(show_deleted), - show_hidden=galaxy.util.string_as_bool(show_hidden)) + show_deleted=string_as_bool(show_deleted), + show_hidden=string_as_bool(show_hidden)) @web.expose @web.json @@ -554,9 +555,9 @@ class HistoryController(BaseUIController, SharableMixin, UsesAnnotations, UsesIt """ View a history. If a history is importable, then it is viewable by any user. """ - show_deleted = galaxy.util.string_as_bool(show_deleted) - show_hidden = galaxy.util.string_as_bool(show_hidden) - use_panels = galaxy.util.string_as_bool(use_panels) + show_deleted = string_as_bool(show_deleted) + show_hidden = string_as_bool(show_hidden) + use_panels = string_as_bool(use_panels) history_dictionary = {} user_is_owner = False @@ -602,7 +603,7 @@ class HistoryController(BaseUIController, SharableMixin, UsesAnnotations, UsesIt """ current_history_id = trans.security.encode_id(trans.history.id) # TODO: allow specifying user_id for admin? - include_deleted_histories = galaxy.util.string_as_bool(include_deleted_histories) + include_deleted_histories = string_as_bool(include_deleted_histories) limit = parse_int(limit, min_val=1, default=10, allow_none=True) return trans.fill_template_mako("history/view_multiple.mako", current_history_id=current_history_id, @@ -690,6 +691,7 @@ class HistoryController(BaseUIController, SharableMixin, UsesAnnotations, UsesIt permissions for the history to private, for future datasets. """ histories = [] + all_histories = string_as_bool(all_histories) if all_histories: histories = trans.user.histories elif history_id: @@ -1074,7 +1076,7 @@ class HistoryController(BaseUIController, SharableMixin, UsesAnnotations, UsesIt @web.expose def resume_paused_jobs(self, trans, current=False, ids=None): """Resume paused jobs the active history -- this does not require a logged in user.""" - if not ids and galaxy.util.string_as_bool(current): + if not ids and string_as_bool(current): histories = [trans.get_history()] refresh_frames = ['history'] else: