Class schmunk42\giiant\commands\BatchController

Inheritanceschmunk42\giiant\commands\BatchController » yii\console\Controller

Public Properties

Hide inherited properties

PropertyTypeDescriptionDefined By
$crudAccessFilter bool Whether to add accessFilter in behavior schmunk42\giiant\commands\BatchController
$crudBaseControllerClass string Base class for crud controllers schmunk42\giiant\commands\BatchController
$crudBaseTraits schmunk42\giiant\commands\BatchController
$crudControllerNamespace string Namespace path for crud controller schmunk42\giiant\commands\BatchController
$crudMessageCategory string The message category for CRUDs used by Yii::t() when $enableI18N is true. schmunk42\giiant\commands\BatchController
$crudPathPrefix string Route prefix for crud controller actions schmunk42\giiant\commands\BatchController
$crudProviders array List of code provider classes (fully namespaced path required) schmunk42\giiant\commands\BatchController
$crudSearchModelNamespace string Namespace path for crud search models schmunk42\giiant\commands\BatchController
$crudSearchModelSuffix string Suffix to append to the search model, setting "Search" will result in a model named "PostSearch" schmunk42\giiant\commands\BatchController
$crudSkipRelations array List of relations to skip, when generating view-views schmunk42\giiant\commands\BatchController
$crudTemplate schmunk42\giiant\commands\BatchController
$crudTidyOutput bool Whether to tidy generated code schmunk42\giiant\commands\BatchController
$crudViewPath string Namespace path for crud views schmunk42\giiant\commands\BatchController
$enableI18N bool Whether the strings will be generated using Yii::t() or normal strings schmunk42\giiant\commands\BatchController
$extendedModels bool Whether to overwrite extended models (from ModelBase) schmunk42\giiant\commands\BatchController
$languageCodeColumn string The column name where the language code is stored schmunk42\giiant\commands\BatchController
$languageTableName string The name of the table containing the translations. schmunk42\giiant\commands\BatchController
$modelBaseClass string Base class for the generated models schmunk42\giiant\commands\BatchController
$modelBaseClassSuffix string Suffix to append to the base model, setting "Base" will result in a model named "PostBase" schmunk42\giiant\commands\BatchController
$modelBaseTraits string Traits for base-models schmunk42\giiant\commands\BatchController
$modelDb string Database application component schmunk42\giiant\commands\BatchController
$modelGenerateHintsFromComments bool This indicates whether the generator should generate attribute hints by using the comments of the corresponding DB columns schmunk42\giiant\commands\BatchController
$modelGenerateLabelsFromComments bool This indicates whether the generator should generate attribute labels by using the comments of the corresponding DB columns schmunk42\giiant\commands\BatchController
$modelGenerateQuery bool Indicates whether to generate ActiveQuery for the ActiveRecord class schmunk42\giiant\commands\BatchController
$modelMessageCategory string The message category for models used by Yii::t() when $enableI18N is true. schmunk42\giiant\commands\BatchController
$modelNamespace string Namespace path for model classes schmunk42\giiant\commands\BatchController
$modelQueryBaseClass string The base class of the new ActiveQuery class schmunk42\giiant\commands\BatchController
$modelQueryNamespace string The namespace of the ActiveQuery class to be generated schmunk42\giiant\commands\BatchController
$modelRemoveDuplicateRelations schmunk42\giiant\commands\BatchController
$overwrite bool Whether to generate and overwrite all files schmunk42\giiant\commands\BatchController
$singularEntities bool Whether the entity names will be singular or the same as the table name schmunk42\giiant\commands\BatchController
$tableNameMap array Mapping for table name to model class names schmunk42\giiant\commands\BatchController
$tablePrefix string Eg. app_ schmunk42\giiant\commands\BatchController
$tables array Table names for generating models and CRUDs schmunk42\giiant\commands\BatchController
$template string The generator template name schmunk42\giiant\commands\BatchController
$useTimestampBehavior bool Whether to use yii\behaviors\TimestampBehavior in models schmunk42\giiant\commands\BatchController
$useTranslatableBehavior bool Whether to use or not 2amigos/yii2-translateable-behavior schmunk42\giiant\commands\BatchController

Protected Properties

Hide inherited properties

PropertyTypeDescriptionDefined By
$appConfig array Application configuration for creating temporary applications schmunk42\giiant\commands\BatchController
$modelGenerator \schmunk42\giiant\commands\instance Of class schmunk42\giiant\generators\model\Generator schmunk42\giiant\commands\BatchController

Public Methods

Hide inherited methods

MethodDescriptionDefined By
actionCruds() Run batch process to generate CRUDs all given tables. schmunk42\giiant\commands\BatchController
actionIndex() Run batch process to generate models and CRUDs for all given tables. schmunk42\giiant\commands\BatchController
actionModels() Run batch process to generate models all given tables. schmunk42\giiant\commands\BatchController
beforeAction() Loads application configuration and checks tables parameter. schmunk42\giiant\commands\BatchController
options() {@inheritdoc} schmunk42\giiant\commands\BatchController

Protected Methods

Hide inherited methods

MethodDescriptionDefined By
getYiiConfiguration() Returns Yii's initial configuration array. schmunk42\giiant\commands\BatchController

Property Details

$appConfig protected property

Application configuration for creating temporary applications

protected array $appConfig null
$crudAccessFilter public property

Whether to add accessFilter in behavior

public bool $crudAccessFilter null
$crudBaseControllerClass public property

Base class for crud controllers

public string $crudBaseControllerClass 'yii\web\Controller'
$crudBaseTraits public property
public $crudBaseTraits null
$crudControllerNamespace public property

Namespace path for crud controller

public string $crudControllerNamespace 'backend\\controllers\\crud'
$crudMessageCategory public property

The message category for CRUDs used by Yii::t() when $enableI18N is true.

        Defaults to `app`
public string $crudMessageCategory 'cruds'
$crudPathPrefix public property

Route prefix for crud controller actions

public string $crudPathPrefix 'crud/'
$crudProviders public property

List of code provider classes (fully namespaced path required)

public array $crudProviders = []
$crudSearchModelNamespace public property

Namespace path for crud search models

public string $crudSearchModelNamespace 'backend\\models\\search'
$crudSearchModelSuffix public property

Suffix to append to the search model, setting "Search" will result in a model named "PostSearch"

$crudSkipRelations public property

List of relations to skip, when generating view-views

$crudTemplate public property
public $crudTemplate 'default'
$crudTidyOutput public property

Whether to tidy generated code

public bool $crudTidyOutput null
$crudViewPath public property

Namespace path for crud views

public string $crudViewPath '@backend/views/crud'
$enableI18N public property

Whether the strings will be generated using Yii::t() or normal strings

public bool $enableI18N true
$extendedModels public property

Whether to overwrite extended models (from ModelBase)

public bool $extendedModels false
$languageCodeColumn public property

The column name where the language code is stored

public string $languageCodeColumn 'language'
$languageTableName public property

The name of the table containing the translations. {{table}} will be replaced with the value in

        "Table Name" field
public string $languageTableName '{{table}}_lang'
$modelBaseClass public property

Base class for the generated models

public string $modelBaseClass 'yii\db\ActiveRecord'
$modelBaseClassSuffix public property

Suffix to append to the base model, setting "Base" will result in a model named "PostBase"

$modelBaseTraits public property

Traits for base-models

public string $modelBaseTraits null
$modelDb public property

Database application component

public string $modelDb 'db'
$modelGenerateHintsFromComments public property

This indicates whether the generator should generate attribute hints by using the comments of the corresponding DB columns

$modelGenerateLabelsFromComments public property

This indicates whether the generator should generate attribute labels by using the comments of the corresponding DB columns

$modelGenerateQuery public property

Indicates whether to generate ActiveQuery for the ActiveRecord class

public bool $modelGenerateQuery true
$modelGenerator protected property

Of class schmunk42\giiant\generators\model\Generator

protected \schmunk42\giiant\commands\instance $modelGenerator null
$modelMessageCategory public property

The message category for models used by Yii::t() when $enableI18N is true.

        Defaults to `app`
public string $modelMessageCategory 'models'
$modelNamespace public property

Namespace path for model classes

public string $modelNamespace 'common\\models'
$modelQueryBaseClass public property

The base class of the new ActiveQuery class

public string $modelQueryBaseClass 'yii\db\ActiveQuery'
$modelQueryNamespace public property

The namespace of the ActiveQuery class to be generated

public string $modelQueryNamespace 'app\models\query'
$modelRemoveDuplicateRelations public property
$overwrite public property

Whether to generate and overwrite all files

public bool $overwrite false
$singularEntities public property

Whether the entity names will be singular or the same as the table name

public bool $singularEntities true
$tableNameMap public property

Mapping for table name to model class names

public array $tableNameMap = []
$tablePrefix public property

Eg. app_

public string $tablePrefix ''
$tables public property

Table names for generating models and CRUDs

public array $tables = []
$template public property

The generator template name

public string $template 'default'
$useTimestampBehavior public property

Whether to use yii\behaviors\TimestampBehavior in models

public bool $useTimestampBehavior true
$useTranslatableBehavior public property

Whether to use or not 2amigos/yii2-translateable-behavior

public bool $useTranslatableBehavior true

Method Details

actionCruds() public method

Run batch process to generate CRUDs all given tables.

public void actionCruds ( )
throws \yii\console\Exception
actionIndex() public method

Run batch process to generate models and CRUDs for all given tables.

public void actionIndex ( )
actionModels() public method

Run batch process to generate models all given tables.

public void actionModels ( )
throws \yii\console\Exception
beforeAction() public method

Loads application configuration and checks tables parameter.

public bool beforeAction ( $action )
$action \yii\base\Action
getYiiConfiguration() protected method

Returns Yii's initial configuration array.

protected array getYiiConfiguration ( )
options() public method

{@inheritdoc}

public void options ( $id )
$id