fix(breadcrumb): update turbo usage with new breadcrumb "api"

This commit is contained in:
Martin 2022-09-06 09:46:53 +02:00 committed by mfo
parent ecbe51f928
commit abbef510c6
2 changed files with 4 additions and 4 deletions

View file

@ -2,7 +2,7 @@
= render partial: 'administrateurs/breadcrumbs', = render partial: 'administrateurs/breadcrumbs',
locals: { steps: [['Démarches', admin_procedures_path], locals: { steps: [['Démarches', admin_procedures_path],
'Nouvelle'] } ['Nouvelle']] }
.procedure-form .procedure-form
.procedure-form__columns.container .procedure-form__columns.container

View file

@ -1,7 +1,7 @@
= turbo_stream.replace 'breadcrumbs' , render(partial: 'administrateurs/breadcrumbs', = turbo_stream.replace 'breadcrumbs' , render(partial: 'administrateurs/breadcrumbs',
locals: { steps: [link_to('Démarches', admin_procedures_path), locals: { steps: [['Démarches', admin_procedures_path],
link_to(@procedure.libelle.truncate_words(10), admin_procedure_path(@procedure)), [@procedure.libelle.truncate_words(4), admin_procedure_path(@procedure)],
'Configuration des champs'], ['Configuration des champs']],
preview: @procedure.draft_revision.valid? }) preview: @procedure.draft_revision.valid? })
= turbo_stream.replace 'errors-summary', render(TypesDeChampEditor::ErrorsSummary.new(revision: @procedure.draft_revision)) = turbo_stream.replace 'errors-summary', render(TypesDeChampEditor::ErrorsSummary.new(revision: @procedure.draft_revision))