Class: AddLicenseTable

Inherits:
ActiveRecord::Migration
  • Object
show all
Defined in:
lib/generators/active_record/add_license_table.rb

Class Method Summary collapse

Class Method Details

.downObject



15
16
17
# File 'lib/generators/active_record/add_license_table.rb', line 15

def self.down
  drop_table :np_licenses
end

.upObject



2
3
4
5
6
7
8
9
10
11
12
13
# File 'lib/generators/active_record/add_license_table.rb', line 2

def self.up
  create_table :np_licenses do |t|
    t.integer :np_identifier_id

    t.string   :taxonomy_code,              :limit => 20        #http://nucc.org/index.php?option=com_wrapper&view=wrapper&Itemid=126
    t.string   :license_number,             :limit => 20
    t.string   :license_number_state_code,  :limit => 2
    t.string   :healthcare_taxonomy_switch, :limit => 1

    t.timestamps
  end
end