baarkerlounger
3 years ago
8 changed files with 79 additions and 10 deletions
@ -1,8 +1,16 @@
|
||||
<%= form_with model: @case_log, builder: GOVUKDesignSystemFormBuilder::FormBuilder do |f| %> |
||||
<%= f.govuk_number_field :age, |
||||
hint: { text: "More detail" }, |
||||
label: { text: "What is the tenant's age?", size: "l"}, |
||||
min: 0, max: 150, step: 1, width: 20 |
||||
%> |
||||
<%= f.govuk_submit %> |
||||
<% end %> |
||||
<div class="govuk-grid-row"> |
||||
<div class="govuk-grid-column-two-thirds"> |
||||
<h1 class="govuk-heading-xl">Tasklist for log |
||||
<%= @case_log.id %></h1> |
||||
|
||||
<h2 class="govuk-heading-s govuk-!-margin-bottom-2">This submission is |
||||
<%= @case_log.status %></h2> |
||||
<p class="govuk-body govuk-!-margin-bottom-7">You've completed 0 of 9 sections.</p> |
||||
<p class="govuk-body govuk-!-margin-bottom-7"> |
||||
<a href="#">Skip to next incomplete section</a> |
||||
</p> |
||||
|
||||
<%= render "tasklist" %> |
||||
|
||||
</div> |
||||
</div> |
||||
|
@ -0,0 +1,8 @@
|
||||
<%= form_with model: @case_log, method: "patch", builder: GOVUKDesignSystemFormBuilder::FormBuilder do |f| %> |
||||
<%= f.govuk_number_field :tenant_age, |
||||
hint: { text: "More detail" }, |
||||
label: { text: "What is the tenant's age?", size: "l"}, |
||||
min: 0, max: 150, step: 1, width: 20 |
||||
%> |
||||
<%= f.govuk_submit "Save and continue" %> |
||||
<% end %> |
@ -0,0 +1,8 @@
|
||||
<%= form_with model: @case_log, method: "patch", builder: GOVUKDesignSystemFormBuilder::FormBuilder do |f| %> |
||||
<%= f.govuk_text_field :tenant_code, |
||||
hint: { text: "More detail" }, |
||||
label: { text: "What is the tenant code?", size: "l"}, |
||||
width: 20 |
||||
%> |
||||
<%= f.govuk_submit "Save and continue" %> |
||||
<% end %> |
@ -0,0 +1,12 @@
|
||||
class AddQuestionFieldsToCaseLogs < ActiveRecord::Migration[6.1] |
||||
def change |
||||
add_column :case_logs, :tenant_code, :string |
||||
add_column :case_logs, :tenant_age, :integer |
||||
add_column :case_logs, :tenant_gender, :string |
||||
add_column :case_logs, :tenant_ethnic_group, :string |
||||
add_column :case_logs, :tenant_nationality, :string |
||||
add_column :case_logs, :previous_housing_situation, :string |
||||
add_column :case_logs, :prior_homelessness, :integer |
||||
add_column :case_logs, :armed_forces, :string |
||||
end |
||||
end |
Loading…
Reference in new issue