page service
This commit is contained in:
parent
10ac3fe693
commit
1fe59c165f
3 changed files with 46 additions and 38 deletions
|
@ -39,6 +39,6 @@
|
||||||
.fr-container
|
.fr-container
|
||||||
%ul.fr-btns-group.fr-btns-group--inline-md
|
%ul.fr-btns-group.fr-btns-group--inline-md
|
||||||
%li
|
%li
|
||||||
= f.submit "Enregistrer", class: "fr-btn"
|
= link_to "Annuler et revenir à l'écran de gestion", admin_procedure_path(id: @procedure.id), class: "fr-btn fr-btn--secondary"
|
||||||
%li
|
%li
|
||||||
= link_to "Annuler et revenir à la page de suivi", admin_procedure_path(id: @procedure.id), class: "fr-btn fr-btn--secondary"
|
= f.submit "Enregistrer", class: "fr-btn"
|
||||||
|
|
|
@ -5,21 +5,22 @@
|
||||||
['Modifier le service']] }
|
['Modifier le service']] }
|
||||||
|
|
||||||
|
|
||||||
.container
|
.fr-container
|
||||||
|
.flex.justify-between.align-center.fr-mb-3w
|
||||||
|
= link_to "Liste de tous les services", admin_services_path(procedure_id: @procedure.id), class: "fr-link fr-icon-arrow-left-line fr-link--icon-left"
|
||||||
|
= link_to "+ Nouveau service", new_admin_service_path(procedure_id: @procedure.id), class: "fr-btn"
|
||||||
|
|
||||||
|
%h1.fr-h2
|
||||||
|
Modifier le service
|
||||||
|
|
||||||
- other_services = @service.procedures.reject {|procedure| procedure.id == @procedure.id }
|
- other_services = @service.procedures.reject {|procedure| procedure.id == @procedure.id }
|
||||||
- if other_services.count > 1
|
- if other_services.count > 1
|
||||||
= render Dsfr::AlertComponent.new(state: :warning, title: "Modifier ce service impactera la ou les démarches qui sont rattachée/s") do |c|
|
= render Dsfr::AlertComponent.new(state: :warning, title: "Modifier ce service impactera la ou les démarches qui sont rattachée/s", extra_class_names: 'fr-mb-3w') do |c|
|
||||||
- c.with_body do
|
- c.with_body do
|
||||||
%ul
|
%ul
|
||||||
- other_services.each do |proc|
|
- other_services.each do |proc|
|
||||||
%li= "#{proc.libelle} (N° #{proc.id})"
|
%li= "#{proc.libelle} (N° #{proc.id})"
|
||||||
%p.mt-3 Si vous souhaitez modifier uniquement les informations pour ce service, créez un nouveau service puis associez-le à la démarche
|
%p.mt-3 Si vous souhaitez modifier uniquement les informations pour ce service, créez un nouveau service puis associez-le à la démarche
|
||||||
|
|
||||||
%p.mt-3
|
|
||||||
= link_to "+ Nouveau service", new_admin_service_path(procedure_id: @procedure.id), class: "fr-btn"
|
|
||||||
|
|
||||||
|
|
||||||
%h1.mt-2 Modifier le service
|
|
||||||
|
|
||||||
= render partial: 'form',
|
= render partial: 'form',
|
||||||
locals: { service: @service, procedure_id: @procedure.id }
|
locals: { service: @service, procedure_id: @procedure.id }
|
||||||
|
|
|
@ -1,13 +1,14 @@
|
||||||
= render partial: 'administrateurs/breadcrumbs',
|
= render partial: 'administrateurs/breadcrumbs',
|
||||||
locals: { steps: [['Démarches', admin_procedures_path],
|
locals: { steps: [['Démarches', admin_procedures_path],
|
||||||
[@procedure.libelle.truncate_words(10), admin_procedure_path(@procedure)],
|
[@procedure.libelle.truncate_words(10), admin_procedure_path(@procedure)],
|
||||||
['Choix du service']] }
|
['Service']] }
|
||||||
|
|
||||||
#services-index.container
|
#services-index.fr-container
|
||||||
%h1.fr-h1 Liste des Services
|
%h1.fr-h2 Service
|
||||||
%h2.fr-h4 La démarche “#{@procedure.libelle}” peut être affectée aux services dans la liste ci-dessous
|
|
||||||
|
|
||||||
%table.fr-table.width-100.mt-3
|
.fr-table.fr-table--layout-fixed
|
||||||
|
%table
|
||||||
|
%caption Liste des services pouvant être affectés à la démarche
|
||||||
%thead
|
%thead
|
||||||
%tr
|
%tr
|
||||||
%th{ scope: "col" }
|
%th{ scope: "col" }
|
||||||
|
@ -32,3 +33,9 @@
|
||||||
method: :delete,
|
method: :delete,
|
||||||
data: { confirm: "Confirmez vous la suppression de #{service.nom}" },
|
data: { confirm: "Confirmez vous la suppression de #{service.nom}" },
|
||||||
class: 'btn btn-link ml-2'
|
class: 'btn btn-link ml-2'
|
||||||
|
|
||||||
|
.padded-fixed-footer
|
||||||
|
.fixed-footer.fr-pb-2w
|
||||||
|
.fr-container
|
||||||
|
= link_to admin_procedure_path(id: @procedure), class: 'fr-link fr-icon-arrow-left-line fr-link--icon-left' do
|
||||||
|
Revenir à l'écran de gestion
|
||||||
|
|
Loading…
Reference in a new issue