Enhanced Yii 2 Advanced Project Template
Yii 2 Advanced Project Template is a skeleton Yii 2 application best for developing complex Web applications with multiple tiers.
The template includes three tiers: front end, back end, and console, each of which is a separate Yii application.
The template is designed to work in a team development environment. It supports deploying the application in different environments.
Improvements that were made by Alexander Sorokin:
- Actions have been grouped in different controllers. No more god-like SiteController! Instead, we have HomeController, CaptchaController, ErrorController, AccountController and so on. Corresponding views have been renamed too.
- Completely standalone authentication for backend and frontend. Now template has model Admin and its own LoginForm, which is used in backend AccountController in conjunction with Captcha.
- Backend contains users CRUD
- Commands "php yii serve-fronted" and "php yii serve-backend" have been added
- Migrations contains default admin user creation. Now after php yii migrate you have fully functional backend admin, which can be accessed via admin \ admin .
- Timestamp to static resources' path has been enabled by default
- Minification and concatenation of static resources have been added (rmrevin/yii2-minify-view)
- localhost in configs has been replaces via 127.0.0.1 due to incompatibility errors on mac os
- Popular kartik' widgets such as gridview, select2 and date-range have been added
- Useful widget for batch operations has been added ( mickgeek/yii2-actionbar )
- Social Auth at frontend has been added (yii2-authclient). Integration with AccountController has been made, but you still need to obtain client id and secret key for services.
- Database schema caching has been enabled for production config
- Date and time default format has been changed to "Y-m-d" and "H:i:S" accordingly
- Pretty urls have been enabled by default
Now, all that you need to start project is:
composer create-project --prefer-dist alexsoftdev/yii2-app-advanced myapp @dev cd myapp php init # select (0)Development or (1)Production # create new database and write its name down at common/configs/main.local, parameter "dsn" php yii migrate php yii serve-backend # Open another terminal window cd myapp php yii serve-frontend # It's alive (c) Victor Frankenstein
Documentation is at docs/guide/README.md.