cirandas.net

ref: master

plugins/push_notification/db/migrate/20160109195305_create_device_tokens.rb


 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
class CreateDeviceTokens < ActiveRecord::Migration
  def change
    create_table :push_notification_plugin_device_tokens do |t|
      t.integer :user_id, null: false
      t.string :device_name, null:false
      t.string :token, null: false, unique: true
      t.timestamps null: false
      t.index :user_id
    end
  end
end