From c601e255e305d522bffce4d8f02ea2c434957929 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1=C5=A1=20Drga?= Date: Sun, 18 Feb 2024 17:08:25 +0100 Subject: [PATCH] Added hidden field, referral code, to first step of registration form --- app/views/services/govbox/_hidden_fields_from_step1.html.erb | 1 + app/views/services/govbox/_hidden_fields_from_step4.html.erb | 3 +-- app/views/services/govbox/register_step1.html.erb | 1 + app/views/services/govbox/register_step4.html.erb | 1 - 4 files changed, 3 insertions(+), 3 deletions(-) diff --git a/app/views/services/govbox/_hidden_fields_from_step1.html.erb b/app/views/services/govbox/_hidden_fields_from_step1.html.erb index b428f205..31ba1a33 100644 --- a/app/views/services/govbox/_hidden_fields_from_step1.html.erb +++ b/app/views/services/govbox/_hidden_fields_from_step1.html.erb @@ -1,3 +1,4 @@ <%= hidden_field_tag :mode, params[:mode], value: params[:mode] || 'sync_mode' %> +<%= hidden_field_tag :referral_code, params[:referral_code] %> <%= hidden_field_tag :legal_subject_name, params[:legal_subject_name] %> <%= hidden_field_tag :cin, params[:cin] %> diff --git a/app/views/services/govbox/_hidden_fields_from_step4.html.erb b/app/views/services/govbox/_hidden_fields_from_step4.html.erb index 3bba9aea..25f7d588 100644 --- a/app/views/services/govbox/_hidden_fields_from_step4.html.erb +++ b/app/views/services/govbox/_hidden_fields_from_step4.html.erb @@ -1,4 +1,3 @@ <%= render 'hidden_fields_from_step3' %> <%= hidden_field_tag :password, params[:password] %> -<%= hidden_field_tag :password_confirmation, params[:password_confirmation] %> -<%= hidden_field_tag :referral_code, params[:referral_code] %> +<%= hidden_field_tag :password_confirmation, params[:password_confirmation] %> \ No newline at end of file diff --git a/app/views/services/govbox/register_step1.html.erb b/app/views/services/govbox/register_step1.html.erb index 17799cb4..7bace487 100644 --- a/app/views/services/govbox/register_step1.html.erb +++ b/app/views/services/govbox/register_step1.html.erb @@ -49,6 +49,7 @@
<%= hidden_field_tag :mode, params[:mode], :value => params[:mode] || 'sync_mode' %> + <%= hidden_field_tag :referral_code, params[:referral_code], :value => params[:referral_code] || cookies[:ref] %> <%= label_tag :legal_subject_name, 'Názov právnickej osoby' %> <%= text_field_tag :legal_subject_name, params[:legal_subject_name], class: 'form-control input-lg', required: true, autocomplete: 'off', data: {'slovensko-digital-autoform': 'name'} %> Napríklad: Slovensko.Digital, Martinus diff --git a/app/views/services/govbox/register_step4.html.erb b/app/views/services/govbox/register_step4.html.erb index 908f01b4..66d6295d 100644 --- a/app/views/services/govbox/register_step4.html.erb +++ b/app/views/services/govbox/register_step4.html.erb @@ -1,7 +1,6 @@
<%= form_tag register_step5_services_govbox_index_path do %> <%= render 'hidden_fields_from_step3' %> - <%= hidden_field_tag :referral_code, cookies[:ref] %>