Browse Source

moved total units to locations

pull/704/head
JG 3 years ago
parent
commit
7ea5673cae
  1. 1
      db/migrate/20220630114748_add_name_to_locations.rb
  2. 1
      db/schema.rb
  3. 3
      db/seeds.rb

1
db/migrate/20220630114748_add_name_to_locations.rb

@ -1,5 +1,6 @@
class AddNameToLocations < ActiveRecord::Migration[7.0] class AddNameToLocations < ActiveRecord::Migration[7.0]
def change def change
add_column :locations, :name, :string add_column :locations, :name, :string
add_column :locations, :total_units, :integer
end end
end end

1
db/schema.rb

@ -248,6 +248,7 @@ ActiveRecord::Schema[7.0].define(version: 2022_07_04_135746) do
t.datetime "created_at", null: false t.datetime "created_at", null: false
t.datetime "updated_at", null: false t.datetime "updated_at", null: false
t.string "name" t.string "name"
t.integer "total_units"
t.index ["scheme_id"], name: "index_locations_on_scheme_id" t.index ["scheme_id"], name: "index_locations_on_scheme_id"
end end

3
db/seeds.rb

@ -76,7 +76,6 @@ unless Rails.env.test?
registered_under_care_act: 0, registered_under_care_act: 0,
support_type: 1, support_type: 1,
scheme_type: 4, scheme_type: 4,
total_units: 5,
intended_stay: "M", intended_stay: "M",
primary_client_group: "O", primary_client_group: "O",
secondary_client_group: "H", secondary_client_group: "H",
@ -90,7 +89,6 @@ unless Rails.env.test?
registered_under_care_act: 1, registered_under_care_act: 1,
support_type: 1, support_type: 1,
scheme_type: 5, scheme_type: 5,
total_units: 2,
intended_stay: "S", intended_stay: "S",
primary_client_group: "D", primary_client_group: "D",
secondary_client_group: "E", secondary_client_group: "E",
@ -104,7 +102,6 @@ unless Rails.env.test?
registered_under_care_act: 1, registered_under_care_act: 1,
support_type: 4, support_type: 4,
scheme_type: 7, scheme_type: 7,
total_units: 7,
intended_stay: "X", intended_stay: "X",
primary_client_group: "G", primary_client_group: "G",
secondary_client_group: "R", secondary_client_group: "R",

Loading…
Cancel
Save