Class: CreateC2dmDevices
- Inherits:
-
ActiveRecord::Migration
- Object
- ActiveRecord::Migration
- CreateC2dmDevices
- Defined in:
- lib/generators/templates/c2dm_migrations/create_c2dm_devices.rb
Overview
:nodoc:
Class Method Summary collapse
Class Method Details
.down ⇒ Object
13 14 15 |
# File 'lib/generators/templates/c2dm_migrations/create_c2dm_devices.rb', line 13 def self.down drop_table :c2dm_devices end |
.up ⇒ Object
2 3 4 5 6 7 8 9 10 11 |
# File 'lib/generators/templates/c2dm_migrations/create_c2dm_devices.rb', line 2 def self.up create_table :c2dm_devices do |t| t.string :registration_id, :size => 120, :null => false t.datetime :last_registered_at t. end add_index :c2dm_devices, :registration_id, :unique => true end |