Sha256: fb152edc74cbd75e38048eb72e7f07e540b9ba7ee80d04e7ee9c11da296e386a

Contents?: true

Size: 225 Bytes

Versions: 4

Compression:

Stored size: 225 Bytes

Contents

class RubyGalleryAddColumnsTo<%= table_name.camelize %> < ActiveRecord::Migration
  def self.up
    add_attachment :<%= table_name %>, :photo
  end
  
  def self.down
    remove_attachment :<%= table_name %>, :photo
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
ruby_gallery-0.1.5 lib/generators/active_record/templates/migration.rb
ruby_gallery-0.1.4 lib/generators/active_record/templates/migration.rb
ruby_gallery-0.1.3 lib/generators/active_record/templates/migration.rb
ruby_gallery-0.1.2 lib/generators/active_record/templates/migration.rb