Sha256: 30546c221e9472c30f2b0b16dd61b61f89669929c1e6ab561339c42838e300d2
Contents?: true
Size: 297 Bytes
Versions: 31
Compression:
Stored size: 297 Bytes
Contents
class CreateRoles < ActiveRecord::Migration def change create_table :roles do |t| t.integer :user_id t.references :ownable, polymorphic: true, index: true t.timestamps null: false end add_index :roles, [:user_id,:ownable_type,:ownable_id], unique: true end end
Version data entries
31 entries across 31 versions & 1 rubygems