What do you think of this files structure?

What do you think of this files structure for a website with frontend and backend?


I would prefer creating a module as backend application

Me too

even for large backoffices ?

define large backoffices

my approach is:

  • generate all models

  • create one administrator module

  • crud all models within administrator module

  • create frontend controllers/views

this is simple and fast because of yii’s built-in generators


Is there any tutorial on how to do this? Also, will gii work from that backend module?

Thank you

Look at gii module (found in framework folder) - best reference example how to use modules for backend purposes.

So, you don’t divide your model into Backend and Frontend parts. Am I right?

I really want to have 3 parts: Backend logic,Frontend logic and shared logic. But I can’t find the right way to do that.

Probably you are right, just leave one model and forget about it… ))