<?php echo $form->field($model, 'url')->textInput(['maxlength' => 512]); ?> <?php echo $form->field($model, 'target')->radioList(Constants::getTargetItems()); ?> <?php echo $form->field($model, 'thumb')->fileInput(['class' => 'da-custom-file']); ?> <?php echo $form->field($model, 'description')->textarea(['maxlength' => 512]); ?> <?php echo $form->field($model, 'sort_num')->textInput(); ?> <?php echo $form->field($model, 'status')->radioList(Constants::getStatusItems()); ?> <?php echo $form->defaultButtons(); ActiveForm::end();
<?= $form->field($model, 'password')->passwordInput(['maxlength' => 64])?> <?= $form->field($model, 'allow_comment')->checkbox([],false)?> <?= $form->field($model, 'is_sticky')->checkbox([],false)?> <?= $form->field($model, 'takonomy_id')->dropDownList($options,['prompt'=>'请选择','options'=>['encodeSpaces'=>true]])?> <?= $form->field($model, 'template')->textInput(['maxlength' => 64])?> <?= $form->field($model, 'comment_count')->textInput()?> <?= $form->field($model, 'view_count')->textInput()?> <?= $form->field($model, 'agree_count')->textInput()?> <?= $form->field($model, 'against_count')->textInput()?> <div class="form-group"> <?= Html::submitButton($model->isNewRecord ? 'Create' : 'Update', ['class' => $model->isNewRecord ? 'btn btn-success' : 'btn btn-primary'])?> </div> </div> </div> <?php ActiveForm::end(); ?> </div>