Sha256: d2789b0652ee6eabba63866f8734329f4cebb69a68aaf8cc96fab760ca0ce4da

Contents?: true

Size: 1.04 KB

Versions: 12

Compression:

Stored size: 1.04 KB

Contents

class CreateUnidomStandards < ActiveRecord::Migration

  def change

    create_table :unidom_standards, id: :uuid do |t|

      t.string :name,     null: false, default: '',  limit: 200
      t.string :number,   null: false, default: '',  limit: 200
      t.string :ics_code, null: true,  default: nil, limit: 64

      t.text :scope_definition
      t.text :corrigenda
      t.text :instruction
      t.text :description

      t.date :published_on, null: false, default: '3000-01-01'
      t.date :applied_on,   null: false, default: '3000-01-01'
      t.date :obsoleted_on, null: false, default: '3000-01-01'

      t.column   :state, 'char(1)', null: false, default: 'C'
      t.datetime :opened_at,        null: false, default: ::Time.utc(1970)
      t.datetime :closed_at,        null: false, default: ::Time.utc(3000)
      t.boolean  :defunct,          null: false, default: false
      t.jsonb    :notation,         null: false, default: {}

      t.timestamps null: false

    end

    add_index :unidom_standards, :number, unique: true

  end

end

Version data entries

12 entries across 12 versions & 1 rubygems

Version Path
unidom-standard-1.4.8 db/migrate/20000601000000_create_unidom_standards.rb
unidom-standard-1.4.7 db/migrate/20000601000000_create_unidom_standards.rb
unidom-standard-1.4.6 db/migrate/20000601000000_create_unidom_standards.rb
unidom-standard-1.4.5 db/migrate/20000601000000_create_unidom_standards.rb
unidom-standard-1.4.4 db/migrate/20000601000000_create_unidom_standards.rb
unidom-standard-1.4.3 db/migrate/20000601000000_create_unidom_standards.rb
unidom-standard-1.4.2 db/migrate/20000601000000_create_unidom_standards.rb
unidom-standard-1.4.1 db/migrate/20000601000000_create_unidom_standards.rb
unidom-standard-1.4 db/migrate/20000601000000_create_unidom_standards.rb
unidom-standard-1.3.6 db/migrate/20000601000000_create_unidom_standards.rb
unidom-standard-1.3.5 db/migrate/20000601000000_create_unidom_standards.rb
unidom-standard-1.3.4 db/migrate/20000601000000_create_unidom_standards.rb