Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/vue.js/6.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Loops 如何以循环的形式显示方框_Loops_Vue.js - Fatal编程技术网

Loops 如何以循环的形式显示方框

Loops 如何以循环的形式显示方框,loops,vue.js,Loops,Vue.js,您好,我想在我的vuejs项目中做一个类似这样的循环 <v-select v-model="create_event.nb_coach" :items="nb_coach" label="number Coach" ></v-select> 我选择一个数字,然后我想在下面显示与上面所选数字相关的此框。我想我的第二个v-select需要一个阵列v型 <v-select v-model="create_event.name_coach" :items="

您好,我想在我的vuejs项目中做一个类似这样的循环

<v-select
 v-model="create_event.nb_coach"
 :items="nb_coach"
 label="number Coach"
></v-select>

我选择一个数字,然后我想在下面显示与上面所选数字相关的此框。我想我的第二个v-select需要一个阵列v型

<v-select
 v-model="create_event.name_coach"
 :items="coach"
 item-text="name"
 label="name Coach"
></v-select>

您可以这样做:

<v-select
 v-for="(item, index) in create_event.nb_coach"
 v-bind:key="index"
 v-model="create_event.name_coach"
 :items="coach"
 item-text="name"
 label="name Coach"
></v-select>