Esempio n. 1
0
?>
 
    <?php 
echo $form->field($model, 'address')->textInput(['maxlength' => 255]);
?>

    <?php 
echo $form->field($model, 'landmark')->textInput(['maxlength' => 255]);
?>

    <?php 
echo $form->field($model, 'entityType')->dropDownList(['' => 'Select', '1' => 'Restaurant', '2' => 'Nightlife']);
?>
     
    <?php 
echo $form->field($model, 'types')->widget(Multiselect::className(), ['data' => ArrayHelper::merge([], ArrayHelper::map(\common\models\Types::find()->andWhere(['status' => 1])->All(), 'Id', 'name')), 'options' => ['multiple' => 'multiple', 'size' => 5, 'title' => 'Select Types']]);
?>
     
    <?php 
echo $form->field($model, 'gpsLat')->textInput();
?>

    <?php 
echo $form->field($model, 'gpsLong')->textInput();
?>

    <?php 
echo $form->field($model, 'hotelId')->widget(DepDrop::classname(), ['options' => ['id' => strtolower($model->formName()) . '-hotelid'], 'data' => ArrayHelper::merge(['' => 'Select'], ArrayHelper::map(\common\models\Hotels::find()->andWhere(['status' => 1, 'cityId' => $model->cityId])->All(), 'Id', 'name')), 'type' => DepDrop::TYPE_SELECT2, 'pluginOptions' => ['depends' => [strtolower($model->formName()) . '-cityid', strtolower($model->formName()) . '-localityid'], 'placeholder' => 'Select Hotel', 'url' => Url::to(['/restaurant/restaurant/hotelsuggest'])]]);
?>
 
Esempio n. 2
0
?>

    <?php 
//<?= $form->field($model, 'guid')->textInput(['maxlength' => 512])
?>

    <?php 
//<?= $form->field($model, 'old_guid')->textInput(['maxlength' => 512])
?>
    
    <?php 
echo $form->field($model, 'cuisines')->dropDownList(ArrayHelper::map(\common\models\Cuisine::find()->andWhere(['status' => 1])->All(), 'Id', 'name'), ['multiple' => 'multiple', 'size' => 5, 'name' => 'Pivot[cuisineId][]']);
?>
    
    <?php 
echo $form->field($model, 'types')->dropDownList(ArrayHelper::map(\common\models\Types::find()->andWhere(['status' => 1])->All(), 'Id', 'name'), ['multiple' => 'multiple', 'size' => 5, 'name' => 'Pivot[typesId][]']);
?>
    
    <?php 
echo $form->field($model, 'feature')->dropDownList(ArrayHelper::map(\common\models\Features::find()->andWhere(['status' => 1])->All(), 'Id', 'name'), ['multiple' => 'multiple', 'size' => 5, 'name' => 'Pivot[featureId][]']);
?>
    
    <?php 
echo $form->field($model, 'payment')->dropDownList(ArrayHelper::map(\common\models\Payments::find()->andWhere(['status' => 1])->All(), 'Id', 'name'), ['multiple' => 'multiple', 'size' => 5, 'name' => 'Pivot[paymentId][]']);
?>

    <div class="form-group">
        <?php 
echo Html::submitButton($model->isNewRecord ? 'Create' : 'Update', ['class' => $model->isNewRecord ? 'btn btn-success' : 'btn btn-primary']);
?>
    </div>