Свойство | Тип | Описание | |
---|---|---|---|
$loadDefaultValues | provides control for model default values populating. If set to false - no default value population will be performed. If set to true - it will invoke loadDefaultValues() method on model. You can set this as a callable of following signature: php function ($model) { populate default values. } | ||
$newModel | a PHP callable that will be called to create the new model. If not set, Create::newModel will be used instead. The signature of the callable should be: php function ($action) { $action is the action object currently running } The callable should return the new model instance. | ||
$view | name of the view, which should be rendered |
Метод | Описание | |
---|---|---|
newModel ( ) : yii\db\ActiveRecordInterface | |
Creates new model instance. | |
run ( ) : mixed | Creates new record. |
Метод | Описание | |
---|---|---|
loadModelDefaultValues ( |
Populates given model with the default values. |
protected loadModelDefaultValues ( |
||
$model | model to be processed. |
public newModel ( ) : yii\db\ActiveRecordInterface | |
||
Результат | yii\db\ActiveRecordInterface | |
new model instance. |
public $loadDefaultValues |
public $newModel |