Browse Source

switched yes and no for wheelchairs

pull/704/head
JG 3 years ago
parent
commit
7d5f53f843
  1. 2
      app/models/location.rb
  2. 2
      app/views/locations/details.html.erb
  3. 2
      app/views/locations/new.html.erb

2
app/models/location.rb

@ -6,8 +6,8 @@ class Location < ApplicationRecord
attr_accessor :add_another_location
WHEELCHAIR_ADAPTATIONS = {
No: 0,
Yes: 1,
No: 0
}.freeze
enum wheelchair_adaptation: WHEELCHAIR_ADAPTATIONS

2
app/views/locations/details.html.erb

@ -37,7 +37,7 @@
:name,
legend: { text: "What is this type of scheme?", size: "m" } %>
<% wheelchair_user_selection = Location.wheelchair_adaptations.keys.reverse.map { |key, _| OpenStruct.new(id: key, name: key.to_s.humanize) } %>
<% wheelchair_user_selection = Location.wheelchair_adaptations.keys.map { |key, _| OpenStruct.new(id: key, name: key.to_s.humanize) } %>
<%= f.govuk_collection_radio_buttons :wheelchair_adaptation,
wheelchair_user_selection,

2
app/views/locations/new.html.erb

@ -37,7 +37,7 @@
:name,
legend: { text: "What is this type of scheme?", size: "m" } %>
<% wheelchair_user_selection = Location.wheelchair_adaptations.keys.reverse.map { |key, _| OpenStruct.new(id: key, name: key.to_s.humanize) } %>
<% wheelchair_user_selection = Location.wheelchair_adaptations.keys.map { |key, _| OpenStruct.new(id: key, name: key.to_s.humanize) } %>
<%= f.govuk_collection_radio_buttons :wheelchair_adaptation,
wheelchair_user_selection,

Loading…
Cancel
Save