From f78e0ced3a46e62f6081bb5423b631a6c017d580 Mon Sep 17 00:00:00 2001 From: Kara Diaby Date: Fri, 30 Oct 2020 18:28:08 +0100 Subject: [PATCH] Revert "feat 5701 - Ajoute l'information lorsqu'un usager s'authentifie via France Connect" --- app/assets/images/logo-france-connect.png | Bin 7451 -> 0 bytes app/views/dossiers/show.pdf.prawn | 3 --- app/views/shared/dossiers/_demande.html.haml | 2 -- app/views/shared/dossiers/_edit.html.haml | 3 +-- .../_france_connect_informations.html.haml | 4 ---- .../france_connect_particulier_spec.rb | 4 ---- .../instructeur/dossiers/show.html.haml_spec.rb | 15 --------------- .../users/dossiers/demande.html.haml_spec.rb | 15 --------------- 8 files changed, 1 insertion(+), 45 deletions(-) delete mode 100644 app/assets/images/logo-france-connect.png delete mode 100644 app/views/shared/dossiers/_france_connect_informations.html.haml diff --git a/app/assets/images/logo-france-connect.png b/app/assets/images/logo-france-connect.png deleted file mode 100644 index c33a3472389d5eecbfed09a1beb14ce074a61f68..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 7451 zcmX|mbySn@|2|5%5mKXj0;3y2N;XE<7$Kd~4U-lT7%9>vwb6n|ODIwTA_yZT1d$vK zQUapiy?>u`e&;;rbzXJ9?(4el=RVILPa?uVlZu>`oQQ~sN?Qw#BqF+nBlv3oVuHQR z+KMLF8-$*TIw9O==Os2MB|HRYPg(tc&K9R2NWX}X+2!EZ)r$LH^8Z^}{UTBWETKwf zfF(2}tGMs6^X_m!DD*M^ZwcT3s$V4F1gFg=m|$gHYr|myZBqJf8sV*y`XyQI7CJG$ zdXY&`ul|gx`+8{zt=MF!XSuw^@21w*^<(W?j=2w=!H9yvi1a01sg&Y@cLl90$vMf6 zF9;I~6zvtYU!0YcO*Qwo2BkmK4z7?hAJem4bPLkaiYGBB)znHD7F0p02le&O&-URu z+i}&}?uSwF5s`2F+>7!;i%R9KCivw=bTcaD%zH)Q_&2SKMKuhF;(P?k*gSJxLMbSt zr^fNQbyS;?M}?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6gE%XCA{y)oz^^uAz2Z z(YC9{S()$Ipk+phQ>q=evb%X>gmY9#_LuYj*^j=l`3hiFMww`(ap8ic)-2XejK=S^ zfhq@^ca7*e!p*eO*l{e0$4dJrJOZgz9uMSbW$3oe87zPE9!vhw*kI(cRw$D=3n(a~ zmGXOHTTY?bjycHKOB~p*EL=(j_#97}5s$N{-wFt} zD0k*h(UrRB%y~*a<)TB|($?mrU44N(e%`%``y zU)@-JOww%<{tG18-#i}8>iP;$V9zX`EK$Ck+=>vErRVKg%QqU^+EriNs65piKg39_ zg)SUw;@Fgm^RojNp-`vBO4IbP!bbq1U~MzJCXVs%_xmRSyEHN`9)(P=b#l(vb!{@T zudr!D(uyy?fvbm2c#-FptLuJz;_Mn@@#G_nRe~y#Vl7yp$1H@`EauP;+inVZ9?DJrY zWf}o{GaDXujwlr`LaOdUudmsrN+!+5*#m6XkH6cJwt}+CA5;i$DF=eGhK%nNUR?DC z8C1W^+dAgPKjk#EX;=`zUtj2JW54u8QjZ>o?8J4vjLx8FhAj_!P@9~D>C}nwFESZIj>x_nrH4{c8U3M6W zr_xq}0oo-OCw^&h09qWiOSJ0UaK;h|5`P`?yR`_jb zs8Y%&k19-NCc|(_z0ewvM0E35hA|LA%J;93>|;>MJpsE6794>G2dmJvV#V+~{|vw5 z2PKl(C>}gbCCH^V8cOoCXU*Mw)>sWOq55Ei5N{mI$OJ;7U%q(Jl0x!Ru;hfr=BXqp w={iAFpibvsLj60>DBr;PtyG9p&7a%4T2YF}=|WJ#PaYy|bp!ZYn0@sB0ba7|umAu6 diff --git a/app/views/dossiers/show.pdf.prawn b/app/views/dossiers/show.pdf.prawn index da7d7f360..36c1c6329 100644 --- a/app/views/dossiers/show.pdf.prawn +++ b/app/views/dossiers/show.pdf.prawn @@ -188,9 +188,6 @@ prawn_document(page_size: "A4") do |pdf| add_title(pdf, "Identité du demandeur") - if @dossier.user.france_connect_information.present? - format_in_2_columns(pdf, 'Informations France Connect', "Le dossier a été déposé par le compte de #{@dossier.individual.prenom} #{@dossier.individual.nom}, authentifié par France Connect le #{@dossier.individual.updated_at.strftime('%d/%m/%Y')}") - end format_in_2_columns(pdf, "Email", @dossier.user.email) add_identite_individual(pdf, @dossier) if @dossier.individual.present? render_identite_etablissement(pdf, @dossier.etablissement) if @dossier.etablissement.present? diff --git a/app/views/shared/dossiers/_demande.html.haml b/app/views/shared/dossiers/_demande.html.haml index 4328a907a..55870541c 100644 --- a/app/views/shared/dossiers/_demande.html.haml +++ b/app/views/shared/dossiers/_demande.html.haml @@ -5,8 +5,6 @@ .tab-title Identité du demandeur .card - - if dossier.user.france_connect_information.present? - = render partial: "shared/dossiers/france_connect_informations", locals: { individual: dossier.individual } = render partial: "shared/dossiers/user_infos", locals: { user: dossier.user } - if dossier.etablissement.present? diff --git a/app/views/shared/dossiers/_edit.html.haml b/app/views/shared/dossiers/_edit.html.haml index a3db1492a..a8a420e3f 100644 --- a/app/views/shared/dossiers/_edit.html.haml +++ b/app/views/shared/dossiers/_edit.html.haml @@ -21,8 +21,7 @@ Votre dossier est enregistré automatiquement après chaque modification. Vous pouvez à tout moment fermer la fenêtre et reprendre plus tard là où vous en étiez. - else Pour enregistrer votre dossier et le reprendre plus tard, cliquez sur le bouton « Enregistrer le brouillon » en bas à gauche du formulaire. - - if !apercu && dossier.user.france_connect_information.present? - = render partial: "shared/dossiers/france_connect_informations", locals: { individual: dossier.individual } + - if notice_url(dossier.procedure).present? = link_to notice_url(dossier.procedure), target: '_blank', rel: 'noopener', class: 'button notice', title: "Pour vous aider à remplir votre dossier, vous pouvez consulter le guide de cette démarche." do %span.icon.info> diff --git a/app/views/shared/dossiers/_france_connect_informations.html.haml b/app/views/shared/dossiers/_france_connect_informations.html.haml deleted file mode 100644 index 125bbbb96..000000000 --- a/app/views/shared/dossiers/_france_connect_informations.html.haml +++ /dev/null @@ -1,4 +0,0 @@ -.card.featured - .flex.justify-center - = image_tag "logo-france-connect.png", alt: "France Connect logo", width: 200, class: "mb-2" - .card-title Le dossier a été déposé par le compte de #{individual.prenom} #{individual.nom}, authentifié par France Connect le #{individual.updated_at.strftime('%d/%m/%Y')}. diff --git a/spec/features/france_connect/france_connect_particulier_spec.rb b/spec/features/france_connect/france_connect_particulier_spec.rb index 37a5171c3..123a10d7d 100644 --- a/spec/features/france_connect/france_connect_particulier_spec.rb +++ b/spec/features/france_connect/france_connect_particulier_spec.rb @@ -68,10 +68,6 @@ feature 'France Connect Particulier Connexion' do scenario 'he is redirected to user dossiers page' do expect(page).to have_content('Dossiers') end - - scenario 'the updated_at date is well updated' do - expect(france_connect_information.updated_at).not_to eq(france_connect_information.created_at) - end end end diff --git a/spec/views/instructeur/dossiers/show.html.haml_spec.rb b/spec/views/instructeur/dossiers/show.html.haml_spec.rb index 48863d240..25072b3e5 100644 --- a/spec/views/instructeur/dossiers/show.html.haml_spec.rb +++ b/spec/views/instructeur/dossiers/show.html.haml_spec.rb @@ -18,19 +18,4 @@ describe 'instructeurs/dossiers/show.html.haml', type: :view do expect(rendered).to have_text('Identité') expect(rendered).to have_text('Demande') end - - context 'when the user is logged in with france connect' do - let(:france_connect_information) { build(:france_connect_information) } - let(:user) { build(:user, france_connect_information: france_connect_information) } - let(:procedure1) { create(:procedure, :with_type_de_champ, for_individual: true) } - let(:dossier) { create(:dossier, procedure: procedure1, user: user) } - - before do - render - end - - it 'fills the individual with the informations from France Connect' do - expect(rendered).to have_text("Le dossier a été déposé par le compte de #{dossier.individual.prenom} #{dossier.individual.nom}, authentifié par France Connect le #{dossier.individual.updated_at.strftime('%d/%m/%Y')}") - end - end end diff --git a/spec/views/users/dossiers/demande.html.haml_spec.rb b/spec/views/users/dossiers/demande.html.haml_spec.rb index a203fc83b..0a46903d4 100644 --- a/spec/views/users/dossiers/demande.html.haml_spec.rb +++ b/spec/views/users/dossiers/demande.html.haml_spec.rb @@ -33,19 +33,4 @@ describe 'users/dossiers/demande.html.haml', type: :view do it { expect(rendered).not_to have_text('Déposé le') } end - - context 'when the user is logged in with france connect' do - let(:france_connect_information) { build(:france_connect_information) } - let(:user) { build(:user, france_connect_information: france_connect_information) } - let(:procedure1) { create(:procedure, :with_type_de_champ, for_individual: true) } - let(:dossier) { create(:dossier, procedure: procedure1, user: user) } - - before do - render - end - - it 'fills the individual with the informations from France Connect' do - expect(rendered).to have_text("Le dossier a été déposé par le compte de #{dossier.individual.prenom} #{dossier.individual.nom}, authentifié par France Connect le #{dossier.individual.updated_at.strftime('%d/%m/%Y')}") - end - end end