The filter is keeping me from posting anything.
I’m totally new to both MVC and Yii. I am fairly good at searching, and I’ve found pages that skirt around the my problem, but none seem to explain an example similar to this:
I have 5 tables:
Each object has an object_type
Each object has 0-to-many detail_type represented through the object_detail_type table, where the value of the detail and, of course, pointers to the object and detail_type exist.
Each object_type has 0-to-many detail_type represented through the object_type_detail_type table, where a list of possible attributes that type can have.
[size="2"]What I want to do:[/size]
Have a single form where I create/edit an object have a dropdown to select the type–at which point it gets a list of detail_type for that object_type and creates the appropriate object_detail_type models.
[size=“2”]This seems like it would be a fairly common thing to do, but I want to do things the “Yii” way and can’t find a reasonable way to do so.[/size]
[size=“2”]This last example I found seems to be doing exactly what I want to do so the manager would be placed over the object_detail_table then you would teach the rest of the Object model to use this for its object_detail_type including first doing a look up on the object_type to determine which detail_type to add. But it’s from a site that is no longer available (at least from my company).[/size]
[size=“2”]I’m kind of on the tract that the Yii way of doing this would be to create an additional CFormModel and controller that would handle both the loading and creation of multiple Models with multiple rows. [/size]
[size=“2”]But as I said I would prefer to do it the Yii way so when I look back I don’t go, “Man, that was stupid. Why did I do all that work when I should have just done blah…”[/size]
Any help would be greatly appreciated!