class BeerDb::CreateDbExtrasNotes

tasting notes (w/ ratings)

Public Instance Methods

up() click to toggle source
# File lib/beerdb/note/schema.rb, line 14
def up
  ActiveRecord::Schema.define do
    create_table :notes do |t| # join table (user,beer)
      t.references :beer, :null => false
      t.references :user, :null => false
      t.integer :rating,  :null => false  # 1-10 scala (10 is best)

      t.text :comments
      t.string :place # location (place) where tasted/drunken

      ## todo: add flag for bottle, can, draft

      t.timestamps
    end
  end # Schema.define
end