2017-06-13 07:44:13 -04:00
|
|
|
# rubocop:disable Migration/Timestamps
|
2016-04-15 03:36:44 -04:00
|
|
|
class CreatePersonalAccessTokens < ActiveRecord::Migration
|
|
|
|
def change
|
|
|
|
create_table :personal_access_tokens do |t|
|
|
|
|
t.references :user, index: true, foreign_key: true, null: false
|
2016-06-14 00:20:14 -04:00
|
|
|
t.string :token, index: { unique: true }, null: false
|
2016-04-15 03:36:44 -04:00
|
|
|
t.string :name, null: false
|
2016-04-22 03:06:56 -04:00
|
|
|
t.boolean :revoked, default: false
|
|
|
|
t.datetime :expires_at
|
2016-04-15 03:36:44 -04:00
|
|
|
|
|
|
|
t.timestamps null: false
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|