I am hoping that someone can kindly offer me a bit of advice for my first Yii project that I am building.
I have successfully create various areas of an administration area where each page has it’s own view, controller and model. It is basically things like users, enquiries and properties etc. so each page is served from a single database table through a model, controller and view.
On one of the sections however I need to create a page that features subpages using Bootstrap tabs and each tab will show content from a different table. For example;
The page is to be a CRM section and each tab will show the following:
Tab 1 - CRM People
Tab 2 - CRM Companies
Tab 3 - CRM Addresses
Tab 4 - CRM Groups
The 4 areas above all already have their own database table but this will be just 1 view.
I am wondering how I go about this? Does each area need to have it’s own model & controller? Do they need to be combined somehow or is there another way of doing this?
I have used renderPartial on some of the other sections so I am now quite familiar with it.
So does that mean I should go ahead and create all of the models and controllers for each of the database tables and bring them in the through renderPartial in the single view?
Sorry to open this post again but I am really struggling with this one now.
I have created a view file for the main CRM page, put the bootstrap tabs widget in and added new tabs to the array. I am then trying to use renderPartial to pull in the index view files of each model including CRM People, CRM Locations and CRM Companies. My view file looks like this: