Files
astuto/db/migrate/20240902151945_create_invitations.rb

15 lines
359 B
Ruby
Raw Permalink Normal View History

2024-09-06 20:27:15 +02:00
class CreateInvitations < ActiveRecord::Migration[6.1]
def change
create_table :invitations do |t|
t.string :email, null: false
t.string :token_digest, null: false
t.datetime :accepted_at
t.references :tenant, null: false, foreign_key: true
t.timestamps
t.index [:email, :tenant_id], unique: true
end
end
end