I have a question about the best way to do model relationships with forms and handlers.
I have two models, groups and grouptypes. I want to have my group edit form have a select list of groups types that allows the user to select a single group type for the group.
Currently, I’m creating a ‘groupTypeID’ form field, and then, in my handler, retrieving the appropriate group and setting the value after I use populateModel().
My problems with this approach are:
a) I use remote proxies with Flex to send strongly typed objects back and forth and therefore, have to maintain separate code to establish these relationships in my handler depending on the origin of the request
b) I have to do a lot of extra typing to accomplish this. While it’s not bad for one association, I have dozens of associations and have a ton of what seems like redundant code throughout my handlers.
So, basically, is this the best/only way to do it, or is there a better approach?