yii2-enhanced-gii icon indicating copy to clipboard operation
yii2-enhanced-gii copied to clipboard

Custom Model Template

Open bwragg opened this issue 5 years ago • 1 comments

Hi,

Is it possible to specify a custom model template using enhanced-gii? Im trying something like this:

'enhanced-gii-model'=>[ 'class' => 'mootensai\enhancedgii\model\Generator', 'templates'=>[ 'isasmodel' => '@backend/custom-gii-templates/model/default', ] ],

but can't see it in the drop down list.

My paths are right because if I do something like this:

'model'=>[ 'class' => 'mootensai\enhancedgii\model\Generator', 'templates'=>[ 'isasmodel' => '@backend/custom-gii-templates/model/default', ] ],

I can see it in the normal Model generator.

Thanks

bwragg avatar Jun 11 '19 08:06 bwragg

@mootensai You need to merge this pull request #153 to fix the Problem

My looks like this one:

` 'enhanced-gii-crud' => [ 'class' => 'mootensai\enhancedgii\crud\Generator', 'templates' => [ 'custom' => '@backend/views/yii2-enhanced-gii/crud/custom/' ] ], 'enhanced-gii-model' => [ 'class' => 'mootensai\enhancedgii\model\Generator', 'templates' => [ 'custom' => '@backend/views/yii2-enhanced-gii/model/custom/' ] ],

`

demonking avatar Jan 02 '20 13:01 demonking