Sha256: db3edca30f4bc8cc4df755a7f05ef8093a161227d1d0a52fd8f6993ddc4acc58
Contents?: true
Size: 1.63 KB
Versions: 1
Compression:
Stored size: 1.63 KB
Contents
class CreateEcomCoreWorkProducts < ActiveRecord::Migration[6.0] def change create_table :ecom_core_work_products do |t| t.string :name, null: false t.string :description t.string :design_reference_no, unique: true t.json :dimension t.references :product_group, null: true, index: { name: 'wp_on_pg_indx' }, foreign_key: { to_table: :ecom_core_product_groups } t.references :work_product_template, null: false, index: { name: 'wpt_on_wp_indx' }, foreign_key: { to_table: :ecom_core_work_product_templates } t.references :project, null: false, index: { name: 'projects_on_wp_indx' }, foreign_key: { to_table: :ecom_core_projects } t.string :status, default: 'New' t.integer :percent_completed, null: false, default: 0 t.string :remark t.references :approver, null: true, index: false, foreign_key: { to_table: :ecom_core_users } t.references :supervisor, null: true, index: false, foreign_key: { to_table: :ecom_core_users } t.references :quality_controller, null: true, index: false, foreign_key: { to_table: :ecom_core_users } t.datetime :start_date t.datetime :completion_date t.timestamps end add_index :ecom_core_work_products, %i[design_reference_no project_id], unique: true, name: 'wp_on_drpi_indx' end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
ecom_core-1.2.15 | db/migrate/20191202235434_create_ecom_core_work_products.rb |