Sha256: a5abd44cc4b84b8a2c9021627d9f7a98c544c141a45ecb8235a85ef8760f7a90

Contents?: true

Size: 668 Bytes

Versions: 98

Compression:

Stored size: 668 Bytes

Contents

class CreateConsultSites < ActiveRecord::Migration[5.1]
  # rubocop:disable Rails/CreateTableWithTimestamps, Rails/ReversibleMigration
  def change
    within_renalware_schema do
      create_table :admission_consult_sites do |t|
        t.string :name, index: :unique
      end

      remove_column :admission_consults, :hospital_unit_id
      add_column :admission_consults, :other_site_or_ward, :string
      add_reference :admission_consults,
                    :consult_site,
                    references: :admission_consult_sites,
                    index: true
    end
  end
  # rubocop:enable Rails/CreateTableWithTimestamps, Rails/ReversibleMigration
end

Version data entries

98 entries across 98 versions & 1 rubygems

Version Path
renalware-core-2.1.1 db/migrate/20171204112150_create_consult_sites.rb
renalware-core-2.1.0 db/migrate/20171204112150_create_consult_sites.rb
renalware-core-2.0.167 db/migrate/20171204112150_create_consult_sites.rb
renalware-core-2.0.166 db/migrate/20171204112150_create_consult_sites.rb
renalware-core-2.0.165 db/migrate/20171204112150_create_consult_sites.rb
renalware-core-2.0.164 db/migrate/20171204112150_create_consult_sites.rb
renalware-core-2.0.163 db/migrate/20171204112150_create_consult_sites.rb
renalware-core-2.0.162 db/migrate/20171204112150_create_consult_sites.rb
renalware-core-2.0.161 db/migrate/20171204112150_create_consult_sites.rb
renalware-core-2.0.160 db/migrate/20171204112150_create_consult_sites.rb
renalware-core-2.0.159 db/migrate/20171204112150_create_consult_sites.rb
renalware-core-2.0.158 db/migrate/20171204112150_create_consult_sites.rb
renalware-core-2.0.157 db/migrate/20171204112150_create_consult_sites.rb
renalware-core-2.0.156 db/migrate/20171204112150_create_consult_sites.rb
renalware-core-2.0.155 db/migrate/20171204112150_create_consult_sites.rb
renalware-core-2.0.153 db/migrate/20171204112150_create_consult_sites.rb
renalware-core-2.0.152 db/migrate/20171204112150_create_consult_sites.rb
renalware-core-2.0.151 db/migrate/20171204112150_create_consult_sites.rb
renalware-core-2.0.149 db/migrate/20171204112150_create_consult_sites.rb
renalware-core-2.0.148 db/migrate/20171204112150_create_consult_sites.rb