From e367cba4807704f5d981492f539c6a016b0fcd72 Mon Sep 17 00:00:00 2001 From: JC Date: Tue, 6 Dec 2016 14:41:50 +0100 Subject: [PATCH] Added condition to show renseigner un siret action in dossiers#show --- app/assets/stylesheets/default_data_block.scss | 9 +++++++-- app/views/backoffice/dossiers/show.html.haml | 11 +++++++++++ app/views/dossiers/_actions.html.haml | 4 ---- app/views/users/recapitulatif/show.html.haml | 11 +++++++++++ 4 files changed, 29 insertions(+), 6 deletions(-) diff --git a/app/assets/stylesheets/default_data_block.scss b/app/assets/stylesheets/default_data_block.scss index 027533077..454b11e9e 100644 --- a/app/assets/stylesheets/default_data_block.scss +++ b/app/assets/stylesheets/default_data_block.scss @@ -35,13 +35,18 @@ color: #FFFFFF; font-size: 18px; font-weight: bold; - .title, .action, .count { - cursor: pointer; + .title, .title-no-expanse, .action, .count { height: 100%; line-height: 40px; padding: 0px; text-transform: uppercase; } + .title-no-expanse { + cursor: not-allowed; + } + .title, .action, .count { + cursor: pointer; + } .action { background-color: #E45B51; text-align: center; diff --git a/app/views/backoffice/dossiers/show.html.haml b/app/views/backoffice/dossiers/show.html.haml index 42c7e55c4..a119f39d6 100644 --- a/app/views/backoffice/dossiers/show.html.haml +++ b/app/views/backoffice/dossiers/show.html.haml @@ -48,6 +48,17 @@ %div.new-action ENVOYER UN MESSAGE + - if @facade.procedure.individual_with_siret + .default_data_block + %div.row.show-block#infos + %div.header + %div.col-lg-8.col-md-8.title-no-expanse + %div.carret-right + INFORMATIONS ENTREPRISE / ASSOCIATION + %div.col-lg-4.col-md-4.action + %a#add_siret.action{href: users_dossier_add_siret_path(dossier_id: @facade.dossier.id)} + = "Renseigner un SIRET" + - unless @facade.entreprise.nil? .default_data_block %div.row.show-block#infos diff --git a/app/views/dossiers/_actions.html.haml b/app/views/dossiers/_actions.html.haml index 3146f7c70..4b9f062a8 100644 --- a/app/views/dossiers/_actions.html.haml +++ b/app/views/dossiers/_actions.html.haml @@ -9,7 +9,3 @@ Modifier les documents %br = render partial: 'users/recapitulatif/modal_upload_pj' - - - if @facade.procedure.individual_with_siret - %a#add_siret.btn.btn-success{href: users_dossier_add_siret_path(dossier_id: @facade.dossier.id)} - = "Renseigner un SIRET" diff --git a/app/views/users/recapitulatif/show.html.haml b/app/views/users/recapitulatif/show.html.haml index 11eafb82d..2dadffaf7 100644 --- a/app/views/users/recapitulatif/show.html.haml +++ b/app/views/users/recapitulatif/show.html.haml @@ -48,6 +48,17 @@ %div.new-action ENVOYER UN MESSAGE + - if @facade.procedure.individual_with_siret + .default_data_block + %div.row.show-block#infos + %div.header + %div.col-lg-8.col-md-8.title-no-expanse + %div.carret-right + INFORMATIONS ENTREPRISE / ASSOCIATION + %div.col-lg-4.col-md-4.action + %a#add_siret.action{href: users_dossier_add_siret_path(dossier_id: @facade.dossier.id)} + = "Renseigner un SIRET" + - unless @facade.entreprise.nil? .default_data_block %div.row.show-block#infos