2012-01-30 20:39:34 +00:00
|
|
|
# -*- encoding : utf-8 -*-
|
2011-10-19 21:58:31 +01:00
|
|
|
class CreateCategories < ActiveRecord::Migration
|
|
|
|
def self.up
|
|
|
|
create_table :categories do |t|
|
|
|
|
t.string :name
|
|
|
|
t.string :ancestry
|
|
|
|
t.integer :projects_count, :default => 0, :null => false
|
|
|
|
|
|
|
|
t.timestamps
|
|
|
|
end
|
|
|
|
end
|
|
|
|
|
|
|
|
def self.down
|
|
|
|
drop_table :categories
|
|
|
|
end
|
|
|
|
end
|