mirror of
https://github.com/czhu12/canine.git
synced 2025-12-21 10:49:49 -06:00
update tokens
This commit is contained in:
@@ -2,10 +2,12 @@ class CreateApiTokens < ActiveRecord::Migration[7.2]
|
||||
def change
|
||||
create_table :api_tokens do |t|
|
||||
t.references :user, null: false, foreign_key: true
|
||||
t.string :name, null: false
|
||||
t.string :access_token, null: false
|
||||
t.datetime :last_used_at
|
||||
t.datetime :expires_at
|
||||
t.timestamps
|
||||
end
|
||||
add_index :api_tokens, :access_token, unique: true
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user