From 8ba3b8ea306b44ffbf297244156085ec8f585e44 Mon Sep 17 00:00:00 2001 From: Stuart Owen Date: Thu, 27 Aug 2026 13:39:22 +0100 Subject: [PATCH 1/3] Consistent ordering of roles on the project roles admin page (#2727) Order the role fields to match the project overview page and the RoleType declaration order: PALs, project administrators, asset housekeepers, asset gatekeepers. --- app/views/projects/admin_member_roles.html.erb | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/app/views/projects/admin_member_roles.html.erb b/app/views/projects/admin_member_roles.html.erb index c8e0611e90..072c5b19ac 100644 --- a/app/views/projects/admin_member_roles.html.erb +++ b/app/views/projects/admin_member_roles.html.erb @@ -16,19 +16,19 @@

<%= form_tag(update_members_project_path(@project)) do %> <%= panel('Administrative Roles') do %> + <% if admin_logged_in? %> + + <%= project_pals_input_box(@project) %> + <% end %> + <%= label_tag("#{t('project_administrator').pluralize}") %> <%= project_administrators_input_box(@project) %> - <%= label_tag("#{t('asset_gatekeeper').pluralize}") %> - <%= project_asset_gatekeepers_input_box(@project) %> - <%= label_tag("#{t('asset_housekeeper').pluralize}") %> <%= project_asset_housekeepers_input_box(@project) %> - <% if admin_logged_in? %> - - <%= project_pals_input_box(@project) %> - <% end %> + <%= label_tag("#{t('asset_gatekeeper').pluralize}") %> + <%= project_asset_gatekeepers_input_box(@project) %> <% end %> <%= submit_tag "Confirm changes", :class => 'btn btn-primary' %> <% end %> From 31608205999933b69e9e0ec6ab6f259f7446a086 Mon Sep 17 00:00:00 2001 From: Stuart Owen Date: Thu, 27 Aug 2026 14:01:00 +0100 Subject: [PATCH 2/3] Move PALs to the end of the role lists (#2727) PALs are the least relevant of the roles, so list them last on both the project overview and the project roles admin page. --- app/views/projects/admin_member_roles.html.erb | 10 +++++----- app/views/projects/show.html.erb | 10 +++++----- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/app/views/projects/admin_member_roles.html.erb b/app/views/projects/admin_member_roles.html.erb index 072c5b19ac..da5a66a2f3 100644 --- a/app/views/projects/admin_member_roles.html.erb +++ b/app/views/projects/admin_member_roles.html.erb @@ -16,11 +16,6 @@

<%= form_tag(update_members_project_path(@project)) do %> <%= panel('Administrative Roles') do %> - <% if admin_logged_in? %> - - <%= project_pals_input_box(@project) %> - <% end %> - <%= label_tag("#{t('project_administrator').pluralize}") %> <%= project_administrators_input_box(@project) %> @@ -29,6 +24,11 @@ <%= label_tag("#{t('asset_gatekeeper').pluralize}") %> <%= project_asset_gatekeepers_input_box(@project) %> + + <% if admin_logged_in? %> + + <%= project_pals_input_box(@project) %> + <% end %> <% end %> <%= submit_tag "Confirm changes", :class => 'btn btn-primary' %> <% end %> diff --git a/app/views/projects/show.html.erb b/app/views/projects/show.html.erb index 7b0259fda1..14300c6038 100644 --- a/app/views/projects/show.html.erb +++ b/app/views/projects/show.html.erb @@ -49,11 +49,6 @@
-

- <%= Seek::Config.instance_admins_name %> <%= t('pal').pluralize %>: - <%= pals_link_list @project -%> -

- <% if @project.respond_to?(:project_coordinators) %>

Project Coordinators: @@ -80,6 +75,11 @@ <%= gatekeepers_link_list @project %>

<% end %> + +

+ <%= Seek::Config.instance_admins_name %> <%= t('pal').pluralize %>: + <%= pals_link_list @project -%> +

<% if @project.start_date %> <%= t('project') -%> start date: From f9d63a21adbc04c47593717d5f5b1bdac8f4bd2a Mon Sep 17 00:00:00 2001 From: Stuart Owen Date: Thu, 27 Aug 2026 14:09:13 +0100 Subject: [PATCH 3/3] Remove the unused project coordinators code Project coordinators were provided by the ProjectPosition model, which was removed in #880. Project never defines project_coordinators, so the respond_to? guard on the show page is always false and the block never renders, making projects_helper#project_coordinators_link_list dead too. --- app/helpers/projects_helper.rb | 4 ---- app/views/projects/show.html.erb | 7 ------- 2 files changed, 11 deletions(-) diff --git a/app/helpers/projects_helper.rb b/app/helpers/projects_helper.rb index eae1f7c9f6..7d467069b1 100644 --- a/app/helpers/projects_helper.rb +++ b/app/helpers/projects_helper.rb @@ -32,10 +32,6 @@ def gatekeepers_link_list(project) link_list_for_role(t('asset_gatekeeper'), project.asset_gatekeepers) end - def project_coordinators_link_list(project) - link_list_for_role('Project coordinator', project.project_coordinators) - end - def programme_link(project) html = if project.try(:programme).nil? "This #{t('project')} is not associated with a #{t('programme')}" diff --git a/app/views/projects/show.html.erb b/app/views/projects/show.html.erb index 14300c6038..617b0b2463 100644 --- a/app/views/projects/show.html.erb +++ b/app/views/projects/show.html.erb @@ -49,13 +49,6 @@

- <% if @project.respond_to?(:project_coordinators) %> -

- Project Coordinators: - <%= project_coordinators_link_list @project %> -

- <% end%> - <% if logged_in_and_registered? %>

<%= t('project_administrator').pluralize %>: