Vue下拉框动态加载数据
<template><a-select v-model="model.type" show-search placeholder="请选择下拉框数据" style="width: 100%"><a-select-option v-for="item in info" v-bind:key="item.id" :value="item.id">{{item.name }}</a-select-option></a-select></template><script>import {httpAction, getAction } from '@/api/manage'export default {name: 'CqTaskForm',components: {},data() {return {info: [],},url: {info: '**********',},},created() {this.getPublisher();},method:{getAction(this.url.info).then((res) => {if(res && res.success) {this.info = res.data}})}}</script>