# Need Suggestion on handling multiple associated models

**URL:** <https://www.ruby-forum.com/t/need-suggestion-on-handling-multiple-associated-models/162043>\
**Category:** Rails\
**Created:** [March 5, 2009, 7:47am UTC](https://www.ruby-forum.com/t/need-suggestion-on-handling-multiple-associated-models/162043 "2009-03-05T07:47:18Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Sahil\_D](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/ee7513/32.png) [@Sahil\_D](https://www.ruby-forum.com/u/Sahil_D)\
**Post date:** [March 5, 2009, 7:47am UTC](https://www.ruby-forum.com/t/need-suggestion-on-handling-multiple-associated-models/162043/1 "2009-03-05T07:47:18Z")

</div>

hi guys…

I am new to rails and need some pointers on how i should handle multiple  
related models.  
’ ’ =\> model  
In my app i am creating and handling some ‘deals’. Each ‘deal’ has got  
some  
‘orders’, and each ‘order’ has certain ‘duties’.  
Now what i am doing currently is, on the new\_deal page itself, i am  
dynamically adding orders for that deal (using attribute\_fu).

I also need some ajax functionality on this page. but that works for  
only  
the fields that are initialy present on the page, when its loaded (as i  
am  
not able to set the id’s for dynamic fields)

Can you guys suggest me some other better way to handle the above  
scenario.  
i have asked at many forums, channels and they always tell me to avoid  
using  
mutiple models in a single page.

## Regards

Sahil
