rest controller
This commit is contained in:
@ -8,6 +8,15 @@ use kernel\modules\post\models\Post;
|
||||
$form = new \itguild\forms\ActiveForm();
|
||||
$form->beginForm(isset($model) ? "/admin/post/edit/" . $model->id : "/admin/post");
|
||||
|
||||
$form->field(\itguild\forms\inputs\TextInput::class, 'title', [
|
||||
'class' => "form-control",
|
||||
'placeholder' => 'Заголовок поста',
|
||||
'value' => $model->title ?? ''
|
||||
])
|
||||
->setLabel("Заголовок")
|
||||
->render();
|
||||
|
||||
|
||||
$form->field(class: \itguild\forms\inputs\TextArea::class, name: "content", params: [
|
||||
'class' => "form-control",
|
||||
'placeholder' => 'Контент',
|
||||
|
Reference in New Issue
Block a user