Hello all,

I've got nested has-many associations working well in DRYML.  Now I'm
trying to do something which should be much simpler, but it doesn't
seem to work for me: nested belongs-to.

An example in "agility" is the story statuses.  The default behaviour
for belongs_to is to add a drop down, but suppose I want a text box to
create a new status (or edit the existing status) instead.

In my app, I can do something like: <do:status>  <input:name /> </do>
or just <input:status.name> and it will create the form properly.
However, when I submit, I get an error like "StoryStatus expected, got
HashWithIndifferentAccess".

In agility, it doesn't actually render,  I get "You have a nil object
when you didn't expect it! The error occurred while evaluating
nil.editable_by?"

This problem is easy to fix in the model by adding a pseudo-attribute
called "status_name" and using <input type="text" name="status_name" /
> in the view.    But this isn't very Hobo-y.

The other issue is that Rails 2.3 has a way of solving this, but Hobo
does not yet support 2.3.  Any comments?

thanks,
Bryan
--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---

Reply via email to