Add breadcrumbs to Fluics page [SCI-8675]

Co-authored-by: Sboursen <dev.sboursen@gmail.com>
This commit is contained in:
sboursen-scinote 2023-06-19 12:20:53 +02:00
parent 36ae7e6ebd
commit ef16771f00
2 changed files with 6 additions and 2 deletions

View file

@ -5,7 +5,7 @@ class LabelPrintersController < ApplicationController
before_action :check_manage_permissions, except: %i(index index_zebra update_progress_modal)
before_action :find_label_printer, only: %i(edit update destroy)
before_action :set_breadcrumbs_items, only: %i(index_zebra)
before_action :set_breadcrumbs_items, only: %i(index_zebra index)
def index
@label_printers = LabelPrinter.all
@ -137,6 +137,9 @@ class LabelPrintersController < ApplicationController
def set_breadcrumbs_items
@breadcrumbs_items = []
printer_label = t('breadcrumbs.fluics_printer')
printer_label = t('breadcrumbs.label_printer') if action_name == 'index_zebra'
@breadcrumbs_items.push({
label: t('breadcrumbs.addons'),
url: addons_path
@ -148,7 +151,7 @@ class LabelPrintersController < ApplicationController
})
else
@breadcrumbs_items.push({
label: t('breadcrumbs.label_printer')
label: printer_label
})
end
end

View file

@ -3624,6 +3624,7 @@ en:
teams: "All Teams"
addons: "Add-Ons"
label_printer: "Label Printer"
fluics_printer: "Fluics Printer"
Add: "Add"
Asset: "File"