[关闭]
@salen 2017-11-20T06:20:48.000000Z 字数 521 阅读 328

快捷操作

未分类


在此输入正文

选择完下拉框后,后面的输入框自动获取焦点

  1. <el-select size="mini" filterable remote default-first-option placeholder=""
  2. placeholder="八位数字"
  3. v-model="detailInfo.params.order_num"
  4. :remote-method="queryOrder"
  5. @change="orderNumChange"
  6. :loading="loading"
  7. ref="order_num">
  8. <el-option
  9. v-for="item in orders"
  10. :key="item.value"
  11. :label="item.label"
  12. :value="item.value">
  13. </el-option>
  14. </el-select>
  15. // 需要根据不同情况判断具体哪个输入框获取焦点,之前下拉框change时触发的时间需要保留
  16. orderNumChange() {
  17. this.getOrderNo()
  18. this.orderType === 0 ?
  19. this.$refs['departure'].focus() : this.$refs['transport_mode'].focus()
  20. }
添加新批注
在作者公开此批注前,只有你和作者可见。
回复批注