Mercurial > hg > soundsoftware-site
comparison lib/generators/redmine_plugin_model/templates/.svn/text-base/migration.rb.erb.svn-base @ 0:513646585e45
* Import Redmine trunk SVN rev 3859
author | Chris Cannam |
---|---|
date | Fri, 23 Jul 2010 15:52:44 +0100 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
-1:000000000000 | 0:513646585e45 |
---|---|
1 class <%= migration_name %> < ActiveRecord::Migration | |
2 def self.up | |
3 create_table :<%= table_name %> do |t| | |
4 <% for attribute in attributes -%> | |
5 t.column :<%= attribute.name %>, :<%= attribute.type %> | |
6 <% end -%> | |
7 end | |
8 end | |
9 | |
10 def self.down | |
11 drop_table :<%= table_name %> | |
12 end | |
13 end |