Browse Source

form and enum changes

pull/216/head
MadeTech Dushan 4 years ago
parent
commit
62d7e2543b
  1. 2
      app/models/case_log.rb
  2. 2
      config/forms/2021_2022.json
  3. 2
      spec/factories/case_log.rb

2
app/models/case_log.rb

@ -48,6 +48,8 @@ class CaseLog < ApplicationRecord
scope :for_organisation, ->(org) { where(owning_organisation: org).or(where(managing_organisation: org)) }
enum status: { "not_started" => 0, "in_progress" => 1, "completed" => 2 }
enum letting_in_sheltered_accomodation: { "Yes - sheltered housing" => 0, "Yes - extra care housing" => 1, "No" => 2, "Don't know" => 3 }
enum ethnic: ETHNIC
enum national: NATIONAL, _suffix: true
enum ecstat1: ECSTAT, _suffix: true

2
config/forms/2021_2022.json

@ -1146,7 +1146,7 @@
"header": "",
"description": "",
"questions": {
"lettinginshelteredaccomodation": {
"letting_in_sheltered_accomodation": {
"check_answer_label": "Is this letting in sheltered accommodation?",
"header": "Is this letting in sheltered accommodation?",
"hint_text": "",

2
spec/factories/case_log.rb

@ -152,7 +152,7 @@ FactoryBot.define do
has_benefits { "Yes" }
is_carehome { "No" }
chcharge { 7 }
letting_in_sheltered_accomodation { 2 }
letting_in_sheltered_accomodation { "No" }
end
created_at { Time.zone.now }
updated_at { Time.zone.now }

Loading…
Cancel
Save