I am attempting to use auto_actions_for within a controller
(property_types_controller.rb) that is supposed to allow for a new and
create within it's child property model. Each time I add this or any
variation of this to the PropertyTypesController:
"auto_actions_for :property, [:new, :create]" I end up getting a
failure in rails with the app simply not starting and the following
output:
Exiting
/Users/username/.rvm/gems/ruby-1.9.2-p180/gems/activesupport-3.0.9/lib/
active_support/whiny_nil.rb:48:in `method_missing': undefined method
`macro' for nil:NilClass (NoMethodError)
from /Users/username/.rvm/gems/ruby-1.9.2-p180/gems/hobo-1.3.0.RC/lib/
hobo/controller/model.rb:266:in `auto_actions_for'
from /Volumes/localdrive/Users/username/project/app/controllers/
property_types_controller.rb:7:in `<class:PropertyTypesController>'
from /Volumes/almaRAID/Users/username/project/app/controllers/
property_types_controller.rb:1:in `<top (required)>'
--END SNIPPET--
Now, when I pluralize the model to properties in the previous
auto_actions_for line, the app seems to work just fine. In the
examples (in the book and on github) I've seen this model is singular,
whereas this seems to behave better when it is plural. Why is this
behaving as such?
Second, in the Properties creation page it already has existing
Property Types, so it appears that it does not show a "New Property
Type" link nor an inline creation section. Is that because there are
existing types? And if so, how do you force it to show one or the
other or both options to create new "property types" in this scenario?
-George
--
You received this message because you are subscribed to the Google Groups "Hobo
Users" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/hobousers?hl=en.