On Lunes, 13 de Julio de 2009 13:08:15 Daniel_cooper escribió:
> If I create a user via the user controller I do, but If I create or
> select a user via the shows controller I don't - thus the User - Role
> relationship is reset when I create a new show.

In a subform, associations always use select form_ui. In show creation you 
should get a user subform to create an associated user and roles column should 
use form_ui select. Do you have has_and_belongs_to_many :roles in your User 
model?

>
> On Jul 13, 10:37 am, "Sergio Cambra .:: entreCables S.L. ::."
>
> <[email protected]> wrote:
> > On Lunes, 13 de Julio de 2009 10:44:42 Daniel_cooper escribió:
> > > With and without, no joy.
> >
> > Don't you get some role checkboxes with form_ui :select?
> >
> > > On Jul 13, 9:14 am, "Sergio Cambra .:: entreCables S.L. ::."
> > >
> > > <[email protected]> wrote:
> > > > On Domingo, 12 de Julio de 2009 23:41:58 Daniel_cooper escribió:
> > > > > Hi,
> > > > >
> > > > > I've got the following setup
> > > > >
> > > > > Role has and belongs to many User
> > > > > User has and belongs to many Show
> > > > >
> > > > > On the show creation form, when I create or select a user for that
> > > > > show I am not presented with a way of choosing the role. If the
> > > > > user had any previous role this is deleted.
> > > > >
> > > > > Is there any way to fix this?
> > > >
> > > > Have you tried with form_ui = :select?
> > > >
> > > > --
> > > > Sergio Cambra .:: entreCables S.L. ::.
> > > > Mariana Pineda 23, 50.018 Zaragoza
> > > > T) 902 021 404 F) 976 52 98 07 E) [email protected]
> >
> > --
> > Sergio Cambra .:: entreCables S.L. ::.
> > Mariana Pineda 23, 50.018 Zaragoza
> > T) 902 021 404 F) 976 52 98 07 E) [email protected]
>
> 
-- 
Sergio Cambra .:: entreCables S.L. ::.
Mariana Pineda 23, 50.018 Zaragoza
T) 902 021 404 F) 976 52 98 07 E) [email protected]


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"ActiveScaffold : Ruby on Rails plugin" 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/activescaffold?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to