2015-12-21 14:40:28 +01:00
|
|
|
#procedure_show
|
2016-06-06 18:25:51 +02:00
|
|
|
=render partial: 'head', locals: {active: 'Informations'}
|
2015-12-21 14:40:28 +01:00
|
|
|
|
2016-06-09 17:49:38 +02:00
|
|
|
-if ! @facade.procedure.published?
|
2016-06-24 16:41:44 +02:00
|
|
|
%a.btn.btn-success{"data-target" => "#publishModal", "data-toggle" => "modal", :type => "button", style:'float: right; margin-top: 10px'}
|
|
|
|
%i.fa.fa-eraser
|
|
|
|
Publier
|
|
|
|
%br
|
|
|
|
=render partial: '/admin/procedures/modal_publish'
|
2016-06-09 17:49:38 +02:00
|
|
|
|
2016-06-24 16:57:35 +02:00
|
|
|
-if @facade.procedure.archived?
|
|
|
|
%a.btn.btn-small.btn-default.text-info{"data-target" => "#publishModal", "data-toggle" => "modal", :type => "button", style:'float: right; margin-top: 10px'}
|
|
|
|
%i.fa.fa-eraser
|
|
|
|
Réactiver
|
|
|
|
%br
|
|
|
|
=render partial: '/admin/procedures/modal_publish'
|
2016-06-09 17:49:38 +02:00
|
|
|
-else
|
|
|
|
= form_tag admin_procedure_archive_path(procedure_id: @facade.procedure.id, archive: !@facade.procedure.archived?), method: :put, style:'float: right; margin-top: 10px' do
|
|
|
|
%button#archive.btn.btn-small.btn-default.text-info{type: :button}
|
|
|
|
%i.fa.fa-eraser
|
2016-06-24 16:57:35 +02:00
|
|
|
= 'Archiver'
|
2016-06-09 17:49:38 +02:00
|
|
|
#confirm
|
|
|
|
%button#valid.btn.btn-small.btn-success{type: :submit}
|
|
|
|
%i.fa.fa-check
|
|
|
|
Valider
|
|
|
|
%button#cancel.btn.btn-small.btn-danger{type: :button}
|
|
|
|
%i.fa.fa-remove
|
|
|
|
Annuler
|
2015-12-21 14:40:28 +01:00
|
|
|
|
2015-12-24 15:57:03 +01:00
|
|
|
- if @facade.procedure.locked?
|
2015-12-21 14:40:28 +01:00
|
|
|
#procedure_locked.center
|
|
|
|
%h5
|
2016-06-09 17:49:38 +02:00
|
|
|
.label.label-info La procédure ne peut plus être modifiée car elle a été publiée
|
2015-12-21 14:40:28 +01:00
|
|
|
|
|
|
|
%div
|
|
|
|
%h3 Lien procédure
|
|
|
|
%div{style:'margin-left:3%'}
|
2016-06-24 16:41:44 +02:00
|
|
|
-if @facade.procedure.archived?
|
|
|
|
%b
|
|
|
|
Cette procédure a été archivée et n'est plus accessible par le public.
|
|
|
|
-elsif @facade.procedure.published?
|
2016-06-09 17:49:38 +02:00
|
|
|
= @facade.procedure.lien
|
|
|
|
-else
|
|
|
|
%b
|
|
|
|
Cette procédure n'a pas encore été publiée et n'est donc pas accessible par le public.
|
2015-12-21 14:40:28 +01:00
|
|
|
|
|
|
|
%br
|
2016-01-06 17:01:34 +01:00
|
|
|
%h3 Détails
|
|
|
|
|
|
|
|
.row{style:'margin-right:3%; margin-left:3%;'}
|
|
|
|
.description.col-md-4.col-lg-4
|
|
|
|
%h4.text-info
|
|
|
|
= @facade.procedure.libelle
|
|
|
|
|
2016-03-24 17:49:44 +01:00
|
|
|
= h @facade.procedure.description.html_safe
|
2016-01-06 17:01:34 +01:00
|
|
|
.champs.col-md-4.col-lg-4
|
|
|
|
%h4.text-info
|
|
|
|
Champs
|
|
|
|
.badge.progress-bar-info
|
|
|
|
= @facade.procedure.types_de_champ.size
|
|
|
|
- @facade.procedure.types_de_champ.each do |champ|
|
|
|
|
= champ.libelle
|
|
|
|
%br
|
|
|
|
|
|
|
|
.pieces_justificatives.col-md-4.col-lg-4
|
|
|
|
%h4.text-info
|
|
|
|
Pièces justificatives
|
|
|
|
.badge.progress-bar-info
|
|
|
|
= @facade.procedure.types_de_piece_justificative.size
|
|
|
|
- @facade.procedure.types_de_piece_justificative.each do |piece_justificative|
|
|
|
|
= piece_justificative.libelle
|
|
|
|
%br
|
|
|
|
%br
|
2015-12-21 14:40:28 +01:00
|
|
|
%h3 Dossiers
|
|
|
|
|
|
|
|
.row
|
|
|
|
.col-md-6.col-lg-6{style:'margin-left:3%'}
|
|
|
|
%h4 Total
|
|
|
|
%div
|
|
|
|
= @facade.dossiers_total
|
|
|
|
|
|
|
|
%h4.text-danger Attente Accompagnateur
|
|
|
|
%div
|
|
|
|
= @facade.dossiers_waiting_gestionnaire_total
|
|
|
|
|
|
|
|
%h4.text-info Attente Utilisateur
|
|
|
|
%div
|
|
|
|
= @facade.dossiers_waiting_user_total
|
|
|
|
|
|
|
|
%h4.text-success Terminé
|
|
|
|
%div
|
|
|
|
= @facade.dossiers_termine_total
|
|
|
|
|
|
|
|
%h4 Archivé
|
|
|
|
|
|
|
|
- unless @facade.dossiers_archived_total == 0
|
|
|
|
%ul
|
|
|
|
- @facade.dossiers_archived_by_state_total.each do |dossier|
|
|
|
|
%li
|
2015-12-24 16:12:16 +01:00
|
|
|
= dossier.display_state
|
2015-12-21 14:40:28 +01:00
|
|
|
\:
|
|
|
|
= dossier.total
|
|
|
|
- else
|
|
|
|
%p
|
|
|
|
0
|
|
|
|
|
|
|
|
.col-md-5.col-lg-5
|
|
|
|
%h4 Non archivés
|
|
|
|
= javascript_include_tag "https://code.highcharts.com/highcharts.js", "chartkick"
|
|
|
|
- if @facade.dossiers_for_pie_highchart.blank?
|
|
|
|
Aucune statistique pour le moment
|
|
|
|
-else
|
|
|
|
=pie_chart @facade.dossiers_for_pie_highchart
|