/** * Show the form for editing the specified resource. * * @param int $id * @return \Illuminate\Http\Response */ public function edit($id) { $cuisine = Cuisine::find($id->id); return view("cuisine._edit", compact('cuisine')); }
?> <?php //$form->field($model, 'created')->textInput(); ?> <?php //$form->field($model, 'modified')->textInput(); ?> <?php echo $form->field($model, 'name')->textInput(['maxlength' => 255]); ?> <?php echo $form->field($model, 'cusine')->dropDownList(ArrayHelper::merge([0 => 'Select'], ArrayHelper::map(\app\models\Cuisine::find()->andWhere(['status' => 1])->All(), 'Id', 'name'))); ?> <?php echo $form->field($model, 'feature')->dropDownList(ArrayHelper::merge([0 => 'Select'], ArrayHelper::map(\app\models\Features::find()->andWhere(['status' => 1])->All(), 'Id', 'name'))); ?> <div class="form-group"> <?php echo Html::submitButton($model->isNewRecord ? 'Create' : 'Update', ['class' => $model->isNewRecord ? 'btn btn-success' : 'btn btn-primary']); ?>