19 lines
560 B
Ruby
19 lines
560 B
Ruby
# frozen_string_literal: true
|
|
|
|
class CreateE621Thumbnails < ActiveRecord::Migration[7.1]
|
|
def change
|
|
create_table(:e621_thumbnails) do |t|
|
|
t.references(:creator, foreign_key: { to_table: :api_users }, null: false)
|
|
t.references(:api_key)
|
|
t.inet(:creator_ip_addr, null: false)
|
|
t.integer(:post_id, null: false)
|
|
t.uuid(:md5, null: false)
|
|
t.string(:status, null: false, default: "pending")
|
|
t.string(:filetype, null: false)
|
|
t.string(:error_code)
|
|
t.datetime(:expires_at)
|
|
t.timestamps
|
|
end
|
|
end
|
|
end
|