Displaying 1 result from an estimated 1 matches for "new_order_observer".
2006 Aug 16
1
Active Record Observers causing 404''s and other weird issues
Hi all. I''ve got a simple AR Observer:
class NewOrderObserver < ActiveRecord::Observer
  observe NewOrder
  def after_create(object)
    Note.create(...)
  end
end
In environment.rb I have the following line:
config.active_record.observers = :new_order_observer
And in application.rb I have:
NewOrderObserver.instance
Aside from simply not working, it''s causing 404''s and telling me that 
certain methods are suddenly no longer available. If I remove those 
three bits of code, everything works fine.
Any ideas? Am I even doing things righ...