photomix/db/migrate/20090520165238_create_photos.rb
2009-05-22 14:13:46 +02:00

14 lines
280 B
Ruby

class CreatePhotos < ActiveRecord::Migration
def self.up
create_table :photos do |t|
t.string :title, :length => 250, :null => false
t.text :description
t.references :album
t.timestamps
end
end
def self.down
drop_table :photos
end
end