[Rails] Re: Referencing named fixtures (is it possible?)

2018-09-23 Thread Frederick Cheung
On Sunday, September 23, 2018 at 5:20:41 PM UTC+1, strzi...@gmail.com wrote: > Hello all, > > I cannot seem to find a way how to reference named fixtures in cases where > Rails fixtures auto-id magic is not working. > > Imagine a model Message with attributes from and to as integers indicating

[Rails] Referencing named fixtures (is it possible?)

2018-09-23 Thread strzibny
Hello all, I cannot seem to find a way how to reference named fixtures in cases where Rails fixtures auto-id magic is not working. Imagine a model Message with attributes from and to as integers indicating users IDs. Now the following fixture won't work: hello_steve: to: steve from: jana

Re: [Rails] ancestry gem creating and editing people view forms

2018-09-23 Thread Nielson Rolim
I'd suggest you create your own solution without ancestry. I had a similar problem. I have an User model and each user must has one or more parents and one or more children. So I created a join table called *users_parents* with two attributes *user_id* and *parent_id*. In my User model I added

[Rails] ancestry gem creating and editing people view forms

2018-09-23 Thread fugee ohu
I wanna create and edit people but ancestry only provides for one parent_id so how can i have two on a form -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To unsubscribe from this group and stop receiving emails from it, send an email