Merge branch 'develop' into develop_v2
# Conflicts: # Gemfile.lock # db/schema.rb
This commit is contained in:
commit
647eaa4ba8
34 changed files with 509 additions and 122 deletions
1
app/views/backoffice/commentaires/index.html.haml
Normal file
1
app/views/backoffice/commentaires/index.html.haml
Normal file
|
@ -0,0 +1 @@
|
|||
= render partial: '/users/recapitulatif/commentaires_flux'
|
|
@ -2,10 +2,30 @@
|
|||
#pref_list_menu
|
||||
= render partial: 'backoffice/dossiers/pref_list'
|
||||
|
||||
=link_to t('dynamics.backoffice.download_all_dossiers'), backoffice_download_dossiers_tps_path, {class: 'btn btn-success btn-sm', style: 'float: right; margin-right: 4%; margin-top: 7px'}
|
||||
%h1
|
||||
=t('dynamics.backoffice.title')
|
||||
|
||||
%div.dropdown.pull-right#download_menu
|
||||
- if @dossiers_list_facade.dossiers_to_display.count > 200
|
||||
%button.btn.btn-error.dropdown-toggle#dropdownDownloadMenu{ type: :button, 'data-toggle' => 'dropdown', 'aria-haspopup' => true, 'aria-expanded' => false, class: 'disabled'}
|
||||
%span{'data-toggle' => :tooltip, "data-placement" => :left, title: 'Pour réduire le nombre de dossiers et ne pas dépasser la limite autorisée de 200, merci de bien vouloir appliquer des filtres.'}
|
||||
= t('dynamics.backoffice.limit_excess_download_all_dossiers')
|
||||
- else
|
||||
%button.btn.btn-success.dropdown-toggle#dropdownDownloadMenu{ type: :button, 'data-toggle' => 'dropdown', 'aria-haspopup' => true, 'aria-expanded' => false }
|
||||
%i.fa.fa-download
|
||||
= t('dynamics.backoffice.download_all_dossiers')
|
||||
%span.caret
|
||||
%ul.dropdown-menu.dropdown-menu-right
|
||||
%li
|
||||
= link_to backoffice_download_dossiers_tps_path(format: :csv, procedure_id: params[:id]), { class: 'btn btn-sm' } do
|
||||
= t('dynamics.backoffice.format_csv')
|
||||
%li
|
||||
= link_to backoffice_download_dossiers_tps_path(format: :xlsx, procedure_id: params[:id]), { class: 'btn btn-sm' } do
|
||||
= t('dynamics.backoffice.format_xlsx')
|
||||
%li
|
||||
= link_to backoffice_download_dossiers_tps_path(format: :ods, procedure_id: params[:id]), { class: 'btn btn-sm' } do
|
||||
= t('dynamics.backoffice.format_ods')
|
||||
|
||||
= render partial: 'backoffice/dossiers/onglets'
|
||||
|
||||
= smart_listing_render :dossiers
|
||||
|
|
|
@ -63,6 +63,12 @@
|
|||
%tr
|
||||
%th{ style: 'width:25%' }
|
||||
=champ.libelle
|
||||
-if gestionnaire_signed_in?
|
||||
=link_to "COM", "", "data-href" => backoffice_dossier_commentaires_path(@facade.dossier, champs_id: champ.id),
|
||||
"data-toggle" => "modal", "data-target" => "#modalCommentairesDossierParChamp"
|
||||
-else
|
||||
=link_to "COM", "", "data-href" => users_dossier_commentaires_path(@facade.dossier, champs_id: champ.id),
|
||||
"data-toggle" => "modal", "data-target" => "#modalCommentairesDossierParChamp"
|
||||
%td
|
||||
-unless champ.decorate.value.blank?
|
||||
=champ.decorate.value.html_safe
|
||||
|
@ -114,3 +120,18 @@
|
|||
%button.action_button.btn.btn-warning
|
||||
%i.fa.fa-circle-o
|
||||
|
||||
#modalCommentairesDossierParChamp.modal.fade{"tabindex" => -1, "role" => "dialog"}
|
||||
.modal-dialog{"role" => "document"}
|
||||
.modal-content
|
||||
.modal-header
|
||||
%button.close{"data-dismiss" => "modal", "aria-label" => "Fermer"}
|
||||
%span{"aria-hidden" => true}
|
||||
×
|
||||
.modal-title
|
||||
Commentaires
|
||||
.modal-body
|
||||
%p
|
||||
Chargement des commentaires en cours...
|
||||
.modal-footer
|
||||
%button.btn.btn-primary{"data-dismiss" => "modal"}
|
||||
Fermer
|
||||
|
|
|
@ -53,6 +53,6 @@
|
|||
|
||||
=link_to 'Contact', "mailto:"+t('dynamics.contact_email')
|
||||
|
||||
|
||||
= render partial: 'layouts/google_analytics'
|
||||
|
||||
|
||||
|
|
1
app/views/users/commentaires/index.html.haml
Normal file
1
app/views/users/commentaires/index.html.haml
Normal file
|
@ -0,0 +1 @@
|
|||
= render partial: '/users/recapitulatif/commentaires_flux'
|
|
@ -1,6 +1,6 @@
|
|||
.content#commentaires_flux{style:'width:100%;'}
|
||||
.content{id: ('commentaires_flux' + (@facade.champ_id.nil? ? '' : "_#{@facade.champ_id}")),style:'width:100%;'}
|
||||
%div#commentaire_new{style: 'width:80%; margin-left:auto; margin-right:auto; margin-bottom:7%'}
|
||||
= form_tag(url_for({ controller: 'commentaires', action: :create, dossier_id: @facade.dossier.id }), class: 'form-inline', method: 'POST', multipart: true) do
|
||||
= form_tag(url_for({ controller: 'commentaires', action: :create, dossier_id: @facade.dossier.id, champ_id: @facade.champ_id }), class: 'form-inline', method: 'POST', multipart: true) do
|
||||
%textarea.form-control{id: 'texte_commentaire', class: 'wysihtml5', name: 'texte_commentaire', style: 'width: 100%; margin-bottom:2%', rows: '5', placeholder:"Commentaire"}
|
||||
%h4.text-primary{style: 'margin-top: 0px'} Ajout un fichier
|
||||
= file_field_tag "piece_justificative[content]", accept: PieceJustificative.accept_format, style: 'float: left; margin-left: 20px'
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue