From 63047c7aa5106909c45b6cc4c6e57f33dc1384b8 Mon Sep 17 00:00:00 2001 From: Anton Date: Fri, 9 May 2025 14:00:28 +0200 Subject: [PATCH] Update breadcrumbs for templates pages [SCI-11874] --- app/controllers/forms_controller.rb | 1 - app/controllers/label_templates_controller.rb | 4 ---- app/controllers/protocols_controller.rb | 1 - app/controllers/storage_locations_controller.rb | 4 ---- config/locales/en.yml | 4 ++-- 5 files changed, 2 insertions(+), 12 deletions(-) diff --git a/app/controllers/forms_controller.rb b/app/controllers/forms_controller.rb index 3ab718384..cbb218d67 100644 --- a/app/controllers/forms_controller.rb +++ b/app/controllers/forms_controller.rb @@ -220,7 +220,6 @@ class FormsController < ApplicationController archived = params[:view_mode] == 'archived' || @form&.archived? @breadcrumbs_items = [] - @breadcrumbs_items.push({ label: t('breadcrumbs.templates') }) @breadcrumbs_items.push( { label: t('breadcrumbs.forms'), url: forms_path(view_mode: archived ? 'archived' : nil) } ) diff --git a/app/controllers/label_templates_controller.rb b/app/controllers/label_templates_controller.rb index 05ae8b82f..dcb312dac 100644 --- a/app/controllers/label_templates_controller.rb +++ b/app/controllers/label_templates_controller.rb @@ -198,10 +198,6 @@ class LabelTemplatesController < ApplicationController def set_breadcrumbs_items @breadcrumbs_items = [] - @breadcrumbs_items.push({ - label: t('breadcrumbs.templates'), - }) - @breadcrumbs_items.push({ label: t('breadcrumbs.labels'), url: label_templates_path diff --git a/app/controllers/protocols_controller.rb b/app/controllers/protocols_controller.rb index 3282a8e8e..3f7f8fe56 100644 --- a/app/controllers/protocols_controller.rb +++ b/app/controllers/protocols_controller.rb @@ -1125,7 +1125,6 @@ class ProtocolsController < ApplicationController archived = params[:view_mode] || (@protocol&.archived? && 'archived') @breadcrumbs_items = [] - @breadcrumbs_items.push({ label: t('breadcrumbs.templates') }) @breadcrumbs_items.push( { label: t('breadcrumbs.protocols'), url: protocols_path(view_mode: archived ? 'archived' : nil) } ) diff --git a/app/controllers/storage_locations_controller.rb b/app/controllers/storage_locations_controller.rb index 9bbd10391..7dfaa437b 100644 --- a/app/controllers/storage_locations_controller.rb +++ b/app/controllers/storage_locations_controller.rb @@ -241,10 +241,6 @@ class StorageLocationsController < ApplicationController def set_breadcrumbs_items @breadcrumbs_items = [] - @breadcrumbs_items.push({ - label: t('breadcrumbs.inventories') - }) - @breadcrumbs_items.push({ label: t('breadcrumbs.locations'), url: storage_locations_path diff --git a/config/locales/en.yml b/config/locales/en.yml index 9f0cb84cc..ae5916da9 100644 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -4802,8 +4802,8 @@ en: templates: "Templates" projects: "Projects" inventories: "Inventories" - protocols: "Protocol" - labels: "Label" + protocols: "Protocol templates" + labels: "Label templates" teams: "All Teams" addons: "Add-ons" locations: "Locations"