features/app/app.rb in pickle-0.1.19 vs features/app/app.rb in pickle-0.1.20

- old
+ new

@@ -26,10 +26,11 @@ t.boolean :rusty, :default => false, :null => false end create_table :users, :force => true do |t| t.string :name, :status, :email + t.decimal :attitude_score, :precision => 4, :scale => 2 end end end @@ -50,22 +51,25 @@ class Tine < ActiveRecord::Base validates_presence_of :fork belongs_to :fork end -# Machinist bluepriint for this +# Machinist blueprint for this class Spoon < ActiveRecord::Base validates_presence_of :name end -# we don;t want abstract classes getting in there +# we don't want abstract classes getting in there class AbstractUser < ActiveRecord::Base self.abstract_class = true end # No factory or blueprint for this class User < AbstractUser validates_presence_of :name + def positive_person? + !attitude_score.nil? && attitude_score > 0 + end end # controllers class DefaultController < ActionController::Base def index \ No newline at end of file