PHP 클래스 yii2tech\admin\actions\Create

부터: 1.0
저자: Paul Klimov ([email protected])
상속: extends Action
파일 보기 프로젝트 열기: yii2tech/admin

공개 프로퍼티들

프로퍼티 타입 설명
$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 | Model Creates new model instance.
run ( ) : mixed Creates new record.

보호된 메소드들

메소드 설명
loadModelDefaultValues ( Model $model ) Populates given model with the default values.

메소드 상세

loadModelDefaultValues() 보호된 메소드

Populates given model with the default values.
protected loadModelDefaultValues ( Model $model )
$model yii\base\Model model to be processed.

newModel() 공개 메소드

Creates new model instance.
public newModel ( ) : yii\db\ActiveRecordInterface | Model
리턴 yii\db\ActiveRecordInterface | yii\base\Model new model instance.

run() 공개 메소드

Creates new record.
public run ( ) : mixed
리턴 mixed response

프로퍼티 상세

$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. }
public $loadDefaultValues

$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.
public $newModel

$view 공개적으로 프로퍼티

name of the view, which should be rendered
public $view