- a-select 标签
<a-form-item
:labelCol="labelCol" :wrapperCol="wrapperCol" label="部门">
<a-select placeholder="请抉择" v-decorator="['departid',{rules: [{ required: true, message:'Please input your data!'}]}]" >
<a-select-option v-for="d in departList" :key="d.departid" :value="d.departid">{{d.departname}}</a-select-option>
</a-select>
</a-form-item>
- 整体思路和 v -for 操作原生的 select 标签十分相似
- 留神有 key 和 value 的值, 两个都要有