Skip to content

Commit

Permalink
Remove 1099 question from DIY flow (#4519)
Browse files Browse the repository at this point in the history
  • Loading branch information
rickreyhsig committed May 7, 2024
1 parent f140d9a commit 6814acc
Show file tree
Hide file tree
Showing 6 changed files with 1 addition and 26 deletions.
3 changes: 1 addition & 2 deletions app/forms/file_yourself_form.rb
@@ -1,11 +1,10 @@
class FileYourselfForm < Form
include FormAttributes
attr_accessor :diy_intake
set_attributes_for :diy_intake, :email_address, :preferred_first_name, :received_1099, :filing_frequency, :referrer, :locale, :visitor_id, :source
set_attributes_for :diy_intake, :email_address, :preferred_first_name, :filing_frequency, :referrer, :locale, :visitor_id, :source

validates :email_address, presence: true, 'valid_email_2/email': { mx: true }
validates :preferred_first_name, presence: true
validates :received_1099, presence: true
validates :filing_frequency, presence: true

def initialize(diy_intake = nil, params = {})
Expand Down
10 changes: 0 additions & 10 deletions app/views/diy/file_yourself/edit.html.erb
Expand Up @@ -21,16 +21,6 @@
<%= f.cfa_input_field(:preferred_first_name, t("views.questions.personal_info.preferred_name"), classes: ["form-width--long"]) %>
<% end %>
<%= f.cfa_input_field(:email_address, t("general.email"), classes: ["form-width--long"]) %>
<%= f.cfa_select(
:received_1099,
t(".received_1099.label"),
[
[I18n.t("general.affirmative"), "yes"],
[I18n.t("general.negative"), "no"],
],
help_text: t(".received_1099.help_text"),
include_blank: true,
) %>
<% unless DiyIntake.should_carry_over_params_from?(current_intake) %>
<%= f.cfa_select(
:filing_frequency,
Expand Down
3 changes: 0 additions & 3 deletions config/locales/en.yml
Expand Up @@ -90,9 +90,6 @@ en:
info:
- File taxes online on your own using our partner website. This is our quickest option for households earning under $79,000 to file taxes and collect the tax credits you are owed!
- To get started, we’ll need to collect some basic information.
received_1099:
help_text: If you were self employed or worked as an independent contractor, you may have gotten a 1099 form.
label: Did you receive a 1099 tax form?
title: File taxes on your own
documents:
documents_help:
Expand Down
3 changes: 0 additions & 3 deletions config/locales/es.yml
Expand Up @@ -91,9 +91,6 @@ es:
info:
- Impuestos
- Para comenzar, necesitaremos recopilar información básica.
received_1099:
help_text: Si trabajaba por cuenta propia o trabajaba como contratista independiente, es posible que haya recibido un formulario 1099.
label: "¿Recibió un formulario de impuestos 1099?"
title: "¡Declare aquí sus impuestos usted mismo!"
documents:
documents_help:
Expand Down
3 changes: 0 additions & 3 deletions spec/controllers/diy/file_yourself_controller_spec.rb
Expand Up @@ -16,7 +16,6 @@
file_yourself_form: {
email_address: "example@example.com",
preferred_first_name: "Robot",
received_1099: "yes",
filing_frequency: "some_years",
}
}
Expand Down Expand Up @@ -57,7 +56,6 @@
existing_diy_intake.reload
expect(existing_diy_intake.email_address).to eq "example@example.com"
expect(existing_diy_intake.preferred_first_name).to eq "Robot"
expect(existing_diy_intake.received_1099).to eq "yes"
expect(existing_diy_intake.filing_frequency).to eq "some_years"

expect(existing_diy_intake.source).to eq "existing_source"
Expand All @@ -80,7 +78,6 @@
file_yourself_form: {
email_address: nil,
preferred_first_name: "Robot",
received_1099: "yes",
filing_frequency: "some_years",
}
}
Expand Down
5 changes: 0 additions & 5 deletions spec/forms/file_yourself_form_spec.rb
Expand Up @@ -6,7 +6,6 @@
{
email_address: "example@example.com",
preferred_first_name: "Robot",
received_1099: "yes",
filing_frequency: "some_years",
}
end
Expand Down Expand Up @@ -35,7 +34,6 @@
diy_intake: {
email_address: "not an email address",
preferred_first_name: "Robot",
received_1099: "yes",
filing_frequency: "some_years",
}
}
Expand All @@ -55,7 +53,6 @@
diy_intake: {
email_address: nil,
preferred_first_name: nil,
received_1099: nil,
filing_frequency: nil,
}
}
Expand All @@ -67,7 +64,6 @@
expect(form).not_to be_valid
expect(form.errors[:email_address]).to be_present
expect(form.errors[:preferred_first_name]).to be_present
expect(form.errors[:received_1099]).to be_present
expect(form.errors[:filing_frequency]).to be_present
end
end
Expand All @@ -82,7 +78,6 @@
diy_intake.reload
expect(diy_intake.email_address).to eq "example@example.com"
expect(diy_intake.preferred_first_name).to eq "Robot"
expect(diy_intake.received_1099).to eq "yes"
expect(diy_intake.filing_frequency).to eq "some_years"
expect(diy_intake.source).to eq "source"
expect(diy_intake.referrer).to eq "referrer"
Expand Down

0 comments on commit 6814acc

Please sign in to comment.