Skip to content

OpenProject is the leading open source project management software for product, project and portfolio management. A powerful Jira alternative with agile planning, issue tracking, roadmaps, Gantt charts, time tracking, collaboration features, and more. Available on premises or in the cloud. ⭐ Star us on GitHub

Introduce PageHeader component in Administration / User settings

Henriette Darge461e620693e5
diff --git a/app/controllers/admin/settings/users_settings_controller.rb b/app/controllers/admin/settings/users_settings_controller.rb
index 8fb79712df0..0f081595191 100644
--- a/app/controllers/admin/settings/users_settings_controller.rb
+++ b/app/controllers/admin/settings/users_settings_controller.rb
@@ -37,12 +37,8 @@ module Admin::Settings
respond_to :html
end
- def default_breadcrumb
- t(:label_user_settings)
- end
-
def show_local_breadcrumb
- true
+ false
end
def settings_params
diff --git a/app/views/admin/settings/users_settings/show.html.erb b/app/views/admin/settings/users_settings/show.html.erb
index 28359cedad8..c412fd7b730 100644
--- a/app/views/admin/settings/users_settings/show.html.erb
+++ b/app/views/admin/settings/users_settings/show.html.erb
@@ -28,7 +28,14 @@ See COPYRIGHT and LICENSE files for more details.
++#%>
<% html_title t(:label_administration), t(:label_user_settings) -%>
-<%= toolbar title: t(:label_user_settings) %>
+<%=
+ render(Primer::OpenProject::PageHeader.new) do |header|
+ header.with_title { t(:label_user_settings) }
+ header.with_breadcrumbs([{ href: admin_index_path, text: t("label_administration") },
+ { href: admin_settings_users_path, text: t(:label_user_and_permission) },
+ t(:label_user_settings)])
+ end
+%>
<%= styled_form_tag(admin_settings_users_path, method: :patch, class: 'admin-settings--form') do %>