Sha256: dfcd78709ff194abfed6ded8eb8b12418d1cb258c684fea1c6269044e3f084bc
Contents?: true
Size: 1.16 KB
Versions: 160
Compression:
Stored size: 1.16 KB
Contents
class CreateComeeCoreContacts < ActiveRecord::Migration[7.1] def change create_table :comee_core_contacts do |t| t.string :first_name, null: false t.string :last_name, null: false t.string :email, null: false t.string :telephone, null: false t.timestamps end create_table :comee_core_suppliers_contacts, id: false do |t| t.references :supplier, null: false, index: {name: "supplier_on_ccsc_indx"}, foreign_key: {to_table: :comee_core_suppliers} t.references :contact, null: false, index: {name: "sc_on_ccsc_indx"}, foreign_key: {to_table: :comee_core_contacts} end create_table :comee_core_clients_contacts, id: false do |t| t.references :client, null: false, index: {name: "client_on_ccsc_indx"}, foreign_key: {to_table: :comee_core_clients} t.references :contact, null: false, index: {name: "cc_on_ccsc_indx"}, foreign_key: {to_table: :comee_core_contacts} end end end
Version data entries
160 entries across 160 versions & 1 rubygems