Class: CreateActivistStatuses

Inherits:
ActiveRecord::Migration
  • Object
show all
Defined in:
lib/generators/activist/install/templates/create_activist_statuses.rb

Class Method Summary collapse

Class Method Details

.downObject



15
16
17
# File 'lib/generators/activist/install/templates/create_activist_statuses.rb', line 15

def self.down
  drop_table :activist_statuses
end

.upObject



2
3
4
5
6
7
8
9
10
11
12
13
# File 'lib/generators/activist/install/templates/create_activist_statuses.rb', line 2

def self.up
  create_table :activist_statuses do |t|
    t.string  :actor_class
    t.integer :actor_id
    t.string  :action
    t.string  :target_class
    t.integer :target_id
    t.text    :data
    
    t.timestamps
  end
end