Sha256: 6452309549493d5b115d75739df177ee47fd76df81c876892d20e337051d4c22
Contents?: true
Size: 969 Bytes
Versions: 15
Compression:
Stored size: 969 Bytes
Contents
# frozen_string_literal: true class AddDeviseInvitableToEacUsersSupportUsers < ( Rails.version < '5' ? ActiveRecord::Migration : ActiveRecord::Migration[4.2] ) def up change_table :eac_users_support_users do |t| t.string :invitation_token t.datetime :invitation_created_at t.datetime :invitation_sent_at t.datetime :invitation_accepted_at t.integer :invitation_limit t.references :invited_by, polymorphic: true t.integer :invitations_count, default: 0 t.index :invitations_count t.index :invitation_token, unique: true # for invitable t.index :invited_by_id end end def down change_table :eac_users_support_users do |t| t.remove_references :invited_by, polymorphic: true t.remove :invitations_count, :invitation_limit, :invitation_sent_at, :invitation_accepted_at, :invitation_token, :invitation_created_at end end end
Version data entries
15 entries across 15 versions & 1 rubygems