We are very pleased to announce the release of Gii extension version 2.0.6. In this release there are many bug fixes and, of course, some enhancements:
Overall ¶
- PHP 7.1 compatibility.
- Aliases could now be used in generator's templates.
- Added filename filter to generated files list preview.
- Added meta tag to prevent indexing of debug by search engines in case it's exposed.
CRUD generator ¶
There are changes in the code generated:
- There are now
@throws
tags for 404 exceptions. NotFoundHttpException
message uses i18n.- Redundant
else
afterreturn
removed. - Removed space from commented out code so when uncommenting in IDEs there's no extra spacing.
- Submit button label was changed from "Update" and "Create" to "Save".
- Changed the way CRUD generator translates "Update X id". Now it's a whole string because of translation difficulties.
Model generator ¶
"Use Table Prefix" and "Generate ActiveQuery" options are now sticky. Additionally, generation itself was improved:
- PostgreSQL got default validator with
null
value for integers in the model andilike
operator in search model. int
andbool
are used instead ofinteger
andboolean
.- FK detection can now recognize
id_something
additionally to existingsomething_id
. - There's an option now to generate relations only for current schema. It's useful for Oracle and MSSQL where reading schema is slow.
- Table comments could now be used for PHPdoc property description.
- Unique validation rule is now generated for tables with multiple primary keys.
See CHANGELOG for details.
Thanks to all contributors who participated in this release.