Recommend this page to a friend! |
Download .zip |
Info | Example | View files (13) | Download .zip | Reputation | Support forum | Blog | Links |
Last Updated | Ratings | Unique User Downloads | Download Rankings | |||||
2024-06-29 (2 hours ago) | Not yet rated by the users | Total: Not yet counted | Not yet ranked |
Version | License | PHP version | Categories | |||
yii2-giitwig 1.0 | MIT/X Consortium ... | 5 | PHP 5, Libraries, Code Generation, De... |
Description | Author | |
This package can be used to implement CRUD applications using Twig templates. |
<?php |
Gii Twig Template Generator (Port default yii2-gii templates) (Without i18N support yet)
The preferred way to install this extension is through composer.
Either run
php composer.phar require --prefer-dist insolita/yii2-giitwig "*"
or add
"insolita/yii2-giitwig": "*"
to the require section of your composer.json
file.
Twig settings
'view'=>[
'class'=>'yii\web\View',
'renderers'=>[
'twig' => [
'class' => 'yii\twig\ViewRenderer',
'cachePath' => '@runtime/Twig/cache',
'options' => [
'auto_reload' => true,
],
'globals' => ['html' => '\yii\helpers\Html','arhelp'=>'\yii\helpers\ArrayHelper','url'=>'yii\helpers\Url'],
'uses' => ['yii\bootstrap'],],
]
]
Gii settings
$config['modules']['gii'] = [
'class'=>'yii\gii\Module',
'generators' => [
'twigcrud' => [
'class' => 'insolita\giitwig\crud\Generator', // generator class
'templates' => [
'twigCrud' => '@insolita/giitwig/crud/default',
]
]
],
];
for customize - copy files from @insolita/giitwig/crud/default to any place, customize and add
$config['modules']['gii'] = [
'class'=>'yii\gii\Module',
'generators' => [
'twigcrud' => [
'class' => 'insolita\giitwig\crud\Generator', // generator class
'templates' => [
'twigCrud' => '@insolita/giitwig/crud/default',
'twigcustomCrud' => '@your/path/to/crud/customized',
]
]
],
];
Files |
File | Role | Description | ||
---|---|---|---|---|
crud (2 files, 1 directory) | ||||
composer.json | Data | Auxiliary data | ||
README.md | Doc. | Documentation |
Files | / | crud |
File | Role | Description | ||
---|---|---|---|---|
default (2 files, 1 directory) | ||||
form.php | Example | Example script | ||
Generator.php | Class | Class source |
Files | / | crud | / | default |
File | Role | Description | ||
---|---|---|---|---|
views (7 files) | ||||
controller.php | Example | Example script | ||
search.php | Example | Example script |
Files | / | crud | / | default | / | views |
File | Role | Description |
---|---|---|
create.php | Example | Example script |
index.php | Example | Example script |
update.php | Example | Example script |
view.php | Example | Example script |
_form.php | Example | Example script |
_listviewitems.php | Example | Example script |
_search.php | Example | Example script |
Version Control | Unique User Downloads | |||||||
100% |
|
Applications that use this package |
If you know an application of this package, send a message to the author to add a link here.