nas/db/migrate/20230320234918_create_scheduled_expiration_statuses.rb
2023-03-21 11:12:33 +09:00

14 lines
461 B
Ruby

# frozen_string_literal: true
class CreateScheduledExpirationStatuses < ActiveRecord::Migration[6.1]
def change
create_table :scheduled_expiration_statuses do |t|
t.belongs_to :account, foreign_key: { on_delete: :cascade }
t.belongs_to :status, null: false, foreign_key: { on_delete: :cascade }
t.datetime :scheduled_at, index: true
t.datetime :created_at, null: false
t.datetime :updated_at, null: false
end
end
end