Akelos Framework v1 forum archive. This forum is no longer maintained. To report bugs please visit https://github.com/akelos/akelos/issues
    • CommentAuthorgizmo
     
    Hello,
    is there a way to build a multi-models form, with validation on all the models involved? I'm building a form to add users to my system, but users' informations span on two tables in the database (let's say 'user' model and 'user_info' model, with has_one/belongs_to association) - so basically i need to collect informations with a single form but i have to write infos to 2 tables. My main problems are:
    1. how can I perform validation on two models at the same time? (it seems that error_messages_for doesn't accept more than one models as parameters)
    2. form fields of the associated object are not propagating their values through the submit action, and error css class is not associated to them: am i missing something or some hacking is needed to make things work?

    Thanks!