1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586 |
- <div class="mb-3 row">
- <label class="col-md-2 col-form-label" >参数标识</label>
- <div class="col-md-10">
- <input type="text" name="setting[sysconfig]" value="<?php echo isset($setting['sysconfig'])?$setting['sysconfig']:'';?>" autocomplete="off" class="form-control" >
- </div>
- </div>
- <div class="mb-3 row">
- <label class="col-md-2 col-form-label" >选项类型</label>
- <div class=" col-md-10">
- <ul class="list-group">
- <li class='list-group-item'>
- <div class='form-check'>
- <input type='radio' name='setting[box_type]' value='radio' class='form-check-input' <?php if(isset($setting['box_type'])&&$setting['box_type']=='radio') echo 'checked';?> >
- <label class='form-check-label'>单选框</label>
- </div>
- </li>
- <li class='list-group-item'>
- <div class='form-check'>
- <input type='radio' name='setting[box_type]' value='checkbox' class='form-check-input' <?php if(isset($setting['box_type'])&&$setting['box_type']=='checkbox') echo 'checked';?> >
- <label class='form-check-label'>复选框</label>
- </div>
- </li>
- <li class='list-group-item'>
- <div class='form-check'>
- <input type='radio' name='setting[box_type]' value='select' class='form-check-input' <?php if(isset($setting['box_type'])&&$setting['box_type']=='select') echo 'checked';?> >
- <label class='form-check-label'>下拉单选</label>
- </div>
- </li>
- <li class='list-group-item'>
- <div class='form-check'>
- <input type='radio' name='setting[box_type]' value='multiple' class='form-check-input' <?php if(isset($setting['box_type'])&&$setting['box_type']=='multiple') echo 'checked';?> >
- <label class='form-check-label'>下拉多选</label>
- </div>
- </li>
- </ul>
- </div>
- </div>
- <div class="mb-3 row">
- <label class="col-md-2 col-form-label" >字段类型</label>
- <div class="col-md-10">
- <select class="form-select " name="setting[field_type]" id="setting_field_type" onchange="if($(this).val()!='varchar'){$('#min_number').show();}else{$('#min_number').hide();}">
- <option value="varchar" <?php if(isset($setting['field_type'])&&$setting['field_type']=='varchar') echo 'selected';?>>字符 VARCHAR</option>
- <option value="tinyint" <?php if(isset($setting['field_type'])&&$setting['field_type']=='tinyint') echo 'selected';?>>整数 TINYINT(3)</option>
- <option value="smallint" <?php if(isset($setting['field_type'])&&$setting['field_type']=='smallint') echo 'selected';?>>整数 SMALLINT(5)</option>
- <option value="mediumint" <?php if(isset($setting['field_type'])&&$setting['field_type']=='mediumint') echo 'selected';?>>整数 MEDIUMINT(8)</option>
- <option value="int" <?php if(isset($setting['field_type'])&&$setting['field_type']=='int') echo 'selected';?>>整数 INT(10)</option>
- </select>
- </div>
- </div>
- <div class="mb-3 row" id="min_number" style="<?php if($setting['field_type']=='varchar'){?> display: none <?php }?>">
- <label class="col-md-2 col-form-label" >整数类型</label>
- <div class=" col-md-10">
- <ul class="list-group">
- <li class='list-group-item'>
- <div class='form-check'>
- <input type='radio' name='setting[min_number]' value='1' class='form-check-input' <?php if(isset($setting['min_number'])&&$setting['min_number']==1) echo 'checked';?>>
- <label class='form-check-label'>正整数</label>
- </div>
- </li>
- <li class='list-group-item'>
- <div class='form-check'>
- <input type='radio' name='setting[min_number]' value='-1' class='form-check-input' <?php if(isset($setting['min_number'])&&$setting['min_number']==-1) echo 'checked';?> >
- <label class='form-check-label'>整数</label>
- </div>
- </li>
- </ul>
- </div>
- </div>
- <div class="mb-3 row">
- <label class="col-md-2 col-form-label" >默认值</label>
- <div class="col-md-10">
- <input type="text" name="setting[default_value]" value="<?php echo isset($setting['default_value'])?$setting['default_value']:'';?>" autocomplete="off" class="form-control" >
- </div>
- </div>
- <div class="mb-3 row" >
- <label class="col-md-2 col-form-label" >筛选字段</label>
- <div class=" col-md-10">
- <input value="1" id="switch-filter_type" type="checkbox" switch="success" class="row-switch" name="setting[filter_type]" <?php if(isset($setting['filter_type'])&&$setting['filter_type']) echo 'checked';?> >
- <label class="switch-check-label " for="switch-filter_type" data-on-label="是" data-off-label="否"></label>
- </div>
- </div>
|