demarches-normaliennes/db/migrate/20190201164951_create_trusted_device_tokens.rb
2019-02-18 17:20:42 +01:00

11 lines
307 B
Ruby

class CreateTrustedDeviceTokens < ActiveRecord::Migration[5.2]
def change
create_table :trusted_device_tokens do |t|
t.string :token, null: false
t.references :gestionnaire, foreign_key: true
t.timestamps
end
add_index :trusted_device_tokens, :token, unique: true
end
end