First thing to consider is the development method, read on test driven, behaviour driven etc. That makes a big different.
Second consideration is the choice of the development system. MVC you started with works for a lot of systems but not for all. If you need to make a chatbox for example there are much better technologies available (think NodeJS etc.) which make life more easy.
MVC in general fits CRUD work and can be extended in many ways but that is the basic approach. Within MVC there are lots of choices more to make. For example: Consider a page with lots of widgets. How would you load every widget. Is that a separate call to the server, it is an internal request, it is a database record etc. Think before starting a project.
MVC: Your thought is wrong:
I also need to create models for each page and this is all confusing to me.
Read a bit more about MVC and about some basic development approaches. For example the feeling that you have to do a lot of duplicate work is not true. In can give you an example of how we quickly setup a concept application. This does not work for all applications but for basic CRUD it works well.
First we build the database tables, so we structure the data in a correct way with the required relations.
We use CakePHP but I expect it is also possible with YII: We set a variable which gives us a basic interface so we can test out and enter some data:
So you get a full (standard) interface where you can work with. It is not customisable but gives a good feeling for the project data.
Generate the models, controllers, views
When satisfied we generate the code for the models, controllers, views (yes: we don't write that out all by hand constantly).
That will give the same look of the application as the scaffold but it generated all needed files.
From here on you start development. Based on your wishes you can start with some layout implementation but it is also possible to first start with some other parts. This is really the step where you start development.
- Remove or add controllers (controllers are not 1-on-1 linked to models!)
- Implement some CSS or stylesheet to get the feeling of the application
- Bake a Plugin to structure code separately (take out the most complex parts)
- Implement model methods to get the right data and call them from the views
- Add custom relations between models
- Implement authentication (don't start with this most of the time).
So, the first steps are thinking about structure (don't try to get the whole application at once) but only the core piece like users, login and the activity (tasks for example).
Then make them good working and good looking. Restructure the standard code you got.
In general it works best to have separate controllers, models, views etc. You are right there is some duplication in it but it is not really duplication. The view action might look the same but is not. It sends other data, requests a specific additional model method etc.