Merge branch 'fix_wording' into develop

This commit is contained in:
Mathieu Magnin 2017-01-31 18:02:41 +01:00
commit 11a7a64bd8
10 changed files with 115 additions and 113 deletions

1
.gitignore vendored
View file

@ -34,3 +34,4 @@ config/fog_credentials.yml
uploads/*
coverage/**/*
.DS_Store
.byebug_history

View file

@ -8,4 +8,12 @@
#individual_with_siret {
display: none;
}
}
.procedure {
&-description {
img {
max-width: 100%;
}
}
}

View file

@ -49,10 +49,10 @@
Cadastre
.col-md-6.col-sm-6.col-xs-6.col-lg-6
%h4 Formulaire / CERFA
%h4 Formulaire de demande ou CERFA
%label
=f.check_box :cerfa_flag
Activer l'envoi de formulaire / CERFA
Activer l'envoi de formulaire de demande ou CERFA
%br
=f.text_field :lien_demarche, class: 'form-control', placeholder: 'URL vers le formulaire vierge (facultatif)'

View file

@ -50,7 +50,7 @@
%b
Cette procédure a été archivée et n'est plus accessible par le public.
- elsif @facade.procedure.published?
= @facade.procedure.lien
= link_to @facade.procedure.lien, @facade.procedure.lien, target: '_blank'
- else
%b
Cette procédure n'a pas encore été publiée et n'est donc pas accessible par le public.
@ -59,12 +59,13 @@
%h3 Détails
.row{style:'margin-right:3%; margin-left:3%;'}
.description.col-md-3.col-sm-3.col-xs-3.col-lg-3
.description.col-xs-6.col-md-3.procedure-description
%h4.text-info
= @facade.procedure.libelle
= h @facade.procedure.description.html_safe
.champs.col-md-3.col-sm-3.col-xs-3.col-lg-3
.champs.col-xs-6.col-md-3
%h4.text-info
Champs
.badge.progress-bar-info
@ -73,7 +74,7 @@
= champ.libelle
%br
.champs_private.col-md-3.col-sm-3.col-xs-3.col-lg-3
.champs_private.col-xs-6.col-md-3
%h4.text-info
Champs privés
.badge.progress-bar-info
@ -82,7 +83,7 @@
= champ.libelle
%br
.pieces_justificatives.col-md-3.col-sm-3.col-xs-3.col-lg-3
.pieces_justificatives.col-xs-6.col-md-3
%h4.text-info
Pièces justificatives
.badge.progress-bar-info

View file

@ -1,57 +1,4 @@
.default_data_block{style:'margin-top: 40px'}
.row.show-block#messages
%div.header
%div.col-lg-10.col-md-10.col-sm-10.col-xs-10.title
.carret-right
.carret-down
MESSAGERIE avec votre
- if user_signed_in?
Administration
- elsif gestionnaire_signed_in?
Usager
%div.col-lg-2.col-md-2.col-sm-2.col-xs-2.count
- message_count = @facade.commentaires.count
= (message_count == 1) ? "1 message" : "#{message_count} messages"
%div.body
- unless @facade.commentaires.empty?
%div.commentaires
- @facade.commentaires.object.sort.each do |commentaire|
= render partial: 'dossiers/commentaire', locals: {commentaire: commentaire}
.row
.col-lg-12.col-md-12.col-sm-12.col-xs-12
%div.split-hr
.row
%div.col-lg-12.col-md-12.col-sm-12.col-xs-12#new-commentaire
= 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'} Ajouter un fichier
= file_field_tag "piece_justificative[content]", accept: PieceJustificative.accept_format, style: 'float: left; margin-left: 20px'
%input#save-message.form-control.btn.btn-send{ type: 'submit', value: 'ENVOYER' }
- if last_comment = @facade.commentaires.first
%div.last-commentaire
.row
%div.col-lg-12.col-md-12.col-sm-12.col-xs-12.comment-header
= "DERNIER MESSAGE (#{last_comment.header})"
.row
%div.col-lg-12.col-md-12.col-sm-12.col-xs-12.content
= last_comment.body.html_safe
- if file = last_comment.piece_justificative
.row
%div.col-lg-12.col-md-12.col-sm-12.col-xs-12.file
= link_to file.content_url, class: 'link', target: '_blank' do
%span.fa.fa-file
%div
= file.original_filename
.row
.col-lg-12.col-md-12.col-sm-12.col-xs-12
%div#open-message.new-action
ENVOYER UN MESSAGE
- else
.last-commentaire
.row
.col-lg-12.col-md-12.col-sm-12.col-xs-12
%div#open-message.new-action
ENVOYER UN MESSAGE
= render partial: 'dossiers/messagerie', locals: { dossier_facade: @facade }
- if @facade.procedure.individual_with_siret
.default_data_block
@ -59,7 +6,7 @@
%div.header
%div.col-lg-8.col-md-8.col-sm-8.col-xs-8.title-no-expanse
%div.carret-right
INFORMATIONS ENTREPRISE / ASSOCIATION
INFORMATIONS DU DEMANDEUR
- if !@current_gestionnaire && ["draft", "updated", "replied", "initiated"].include?(@facade.dossier.state)
%a#add_siret.action{href: users_dossier_add_siret_path(dossier_id: @facade.dossier.id)}
%div.col-lg-4.col-md-4.col-sm-4.col-xs-4.action
@ -72,7 +19,7 @@
%div.col-lg-12.col-md-12.col-sm-12.col-xs-12.title
%div.carret-right
%div.carret-down
INFORMATIONS ENTREPRISE / ASSOCIATION
INFORMATIONS DU DEMANDEUR
%div.body
= render partial: '/dossiers/infos_entreprise'
@ -118,4 +65,3 @@
= (private_fields_count == 1) ? "1 champ" : "#{private_fields_count} champs"
%div.body
= render partial: '/dossiers/infos_private_fields'

View file

@ -0,0 +1,47 @@
.default_data_block{style:'margin-top: 40px'}
.row.show-block.clearfix#messages
.header
.col-xs-10.title
.carret-right
.carret-down
MESSAGERIE
.col-xs-2.count
- message_count = dossier_facade.commentaires.count
= (message_count == 1) ? "1 message" : "#{message_count} messages"
.alert.alert-info
Cette messagerie permet d'échanger entre le demandeur et le service instructeur.
.body
- if dossier_facade.commentaires.any?
.commentaires
= render partial: 'dossiers/commentaire', collection: dossier_facade.commentaires.object.sort
.split-hr
#new-commentaire
= form_tag(url_for({ controller: 'commentaires', action: :create, dossier_id: dossier_facade.dossier.id, champ_id: dossier_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"}
.row
.col-md-6
%h4.text-primary{style: 'margin-top: 0px'} Ajouter un fichier
= file_field_tag "piece_justificative[content]", accept: PieceJustificative.accept_format, style: 'float: left; margin-left: 20px'
.col-md-6
%input#save-message.form-control.btn.btn-send{ type: 'submit', value: 'ENVOYER' }
.last-commentaire.clearfix
- if last_comment = dossier_facade.commentaires.first
%div
DERNIER MESSAGE
= render partial: 'dossiers/commentaire', object: last_comment
-# = "DERNIER MESSAGE (#{last_comment.header})"
-# .content
-# = last_comment.body.html_safe
-# - if file = last_comment.piece_justificative
-# .file
-# = link_to file.content_url, class: 'link', target: '_blank' do
-# %span.fa.fa-file
-# = file.original_filename
#open-message.new-action
ENVOYER UN MESSAGE

View file

@ -1,30 +1,33 @@
.row
.col-lg-8.col-lg-push-1
%table.table
- if @dossier.procedure.cerfa_flag
%tr
%th.col-lg-6
='Formulaire / CERFA (complété et numérisé)'
-unless dossier.procedure.lien_demarche.blank?
%p
Récupérer le formulaire de demande ou CERFA vierge pour mon dossier :
= link_to "Télécharger", dossier.procedure.lien_demarche, target: '_blank', id: 'lien_cerfa'
%td.col-lg-5
-if @dossier.cerfa_available?
%span.btn.btn-sm.btn-file.btn-success
Modifier
%input{type: 'file', name:'cerfa_pdf', id:'cerfa_pdf', accept: PieceJustificative.accept_format, :max_file_size => 6.megabytes }
-else
%input{type: 'file', name:'cerfa_pdf', id:'cerfa_pdf', accept: PieceJustificative.accept_format, :max_file_size => 6.megabytes }
%table.table
- if dossier.procedure.cerfa_flag
%tr
%th.col-lg-6
Formulaire de demande ou CERFA (complété et numérisé)
- @dossier.types_de_piece_justificative.order('order_place ASC').each do |type_de_piece_justificative|
%tr
%th.col-lg-6.piece-libelle
= type_de_piece_justificative.libelle
%td.col-lg-5
-if type_de_piece_justificative.api_entreprise
%span.text-success{ id: "piece_justificative_#{type_de_piece_justificative.id}" } Nous l'avons récupéré pour vous.
-else
-if @dossier.retrieve_last_piece_justificative_by_type(type_de_piece_justificative.id).nil?
= file_field_tag "piece_justificative_#{type_de_piece_justificative.id}", accept: PieceJustificative.accept_format, :max_file_size => 6.megabytes
-else
%span.btn.btn-sm.btn-file.btn-success
Modifier
= file_field_tag "piece_justificative_#{type_de_piece_justificative.id}", accept: PieceJustificative.accept_format, :max_file_size => 6.megabytes
%td.col-lg-5
-if dossier.cerfa_available?
%span.btn.btn-sm.btn-file.btn-success
Modifier
%input{type: 'file', name:'cerfa_pdf', id:'cerfa_pdf', accept: PieceJustificative.accept_format, :max_file_size => 6.megabytes }
-else
%input{type: 'file', name:'cerfa_pdf', id:'cerfa_pdf', accept: PieceJustificative.accept_format, :max_file_size => 6.megabytes }
- dossier.types_de_piece_justificative.order('order_place ASC').each do |type_de_piece_justificative|
%tr
%th.col-lg-6.piece-libelle
= type_de_piece_justificative.libelle
%td.col-lg-5
-if type_de_piece_justificative.api_entreprise
%span.text-success{ id: "piece_justificative_#{type_de_piece_justificative.id}" } Nous l'avons récupéré pour vous.
-else
-if dossier.retrieve_last_piece_justificative_by_type(type_de_piece_justificative.id).nil?
= file_field_tag "piece_justificative_#{type_de_piece_justificative.id}", accept: PieceJustificative.accept_format, :max_file_size => 6.megabytes
-else
%span.btn.btn-sm.btn-file.btn-success
Modifier
= file_field_tag "piece_justificative_#{type_de_piece_justificative.id}", accept: PieceJustificative.accept_format, :max_file_size => 6.megabytes

View file

@ -24,15 +24,10 @@
%br
%h3 Documents administratifs
-unless @procedure.lien_demarche.blank?
%p
Récupérer le formulaire / CERFA vierge pour mon dossier :
%a{style:'font-size:0.9em; padding-left:3px', id: 'lien_cerfa' ,href: "#{@procedure.lien_demarche}", :target => '_blank'} Télécharger
%br
//TODO a refactorer
= render partial: 'users/description/pieces_justificatives'
.row
.col-lg-8
= render partial: 'users/description/pieces_justificatives', locals: { dossier: @dossier }
- unless Features.opensimplif
#state_description.row{style:'width: 50%; margin-left:20px'}

View file

@ -11,7 +11,7 @@
Modification des documents
.modal-body
= render partial: 'users/description/pieces_justificatives'
= render partial: 'users/description/pieces_justificatives', locals: { dossier: @dossier }
.modal-footer
= submit_tag 'Modification terminée', class: %w(btn btn btn-info), id: 'modification_terminee', data: { disable_with: 'Modification terminée', submit: true}

View file

@ -1,19 +1,20 @@
- if @dossier
= link_to 'X', users_no_procedure_url, class: 'btn btn-xs', style:'float: right'
.panel.panel-default
.panel-body
= link_to 'X', users_no_procedure_url, class: 'btn btn-xs', style:'float: right'
- if @dossier.procedure.euro_flag
#euro_flag.flag
=image_tag('drapeau_europe.png')
- if @dossier.procedure.euro_flag
#euro_flag.flag
=image_tag('drapeau_europe.png')
#logo_procedure.flag
=image_tag( @dossier.procedure.decorate.logo_img )
#logo_procedure.flag
=image_tag( @dossier.procedure.decorate.logo_img )
%h2#titre_procedure.text-info
= @dossier.procedure.libelle
%p
= h @dossier.procedure.description.html_safe
%h2#titre_procedure.text-info
= @dossier.procedure.libelle
%p.procedure-description
= h @dossier.procedure.description.html_safe
- else
#logo_procedure.flag
= image_tag(image_url(LOGO_NAME), {id: 'logo_tps'})
%br