_form.php 1.4 KB

123456789101112131415161718192021222324252627282930313233343536373839
  1. <?php
  2. use yii\helpers\Html;
  3. use yii\widgets\ActiveForm;
  4. /* @var $this yii\web\View */
  5. /* @var $model common\models\ShareLevel */
  6. /* @var $form yii\widgets\ActiveForm */
  7. ?>
  8. <div class="box box-success">
  9. <div class="box-body">
  10. <?php $form = ActiveForm::begin(); ?>
  11. <?= $form->field($model, 'title')->textInput(['maxlength' => true]) ?>
  12. <?= $form->field($model, 'sale_rate')->hint('请填写小数,0.1 = 10%')->textInput() ?>
  13. <?= $form->field($model, 'direct_rate')->hint('请填写小数,0.1 = 10%')->textInput() ?>
  14. <?= $form->field($model, 'put_on_rate')->hint('请填写小数,0.1 = 10%')->textInput() ?>
  15. <?= $form->field($model, 'price')->textInput(['maxlength' => true]) ?>
  16. <?= $form->field($model, 'upgrade_limit')->hint('有多少个初级合伙人级别的下级,非初级合伙人设置此项')->textInput(['type' => 'number']) ?>
  17. <?= $form->field($model, 'is_base')->hint('只能设置一个,升级按此级别统计')->checkbox() ?>
  18. <?= $form->field($model, 'base_limit')->hint('销售订单数量,勾选是否初级合伙人才生效')->textInput(['type' => 'number']) ?>
  19. <div class="form-group">
  20. <?= Html::submitButton($model->isNewRecord ? Yii::t('common', 'Create') : Yii::t('common', 'Update'), ['class' => $model->isNewRecord ? 'btn btn-success btn-flat' : 'btn btn-primary btn-flat']) ?>
  21. </div>
  22. <?php ActiveForm::end(); ?>
  23. </div>
  24. </div>