Bootstrap-vue dynamic multiple item row radio button selection not selected individual radio item
Here is my Vue data
property and the list array:
data() {
return {
dataList: [],
question_option: '',
}
I am showing my radio button groups dynamically based on dataList
in Bootstrap-Vue.
<ul class="question_list" v-for="(item, index) in dataList" :key="index">
<li>
<p><b>{{ index + 1 + '. ' + item.question }}</b></p>
<b-form-group :id="index.toString()" :name="index.toString()">
<b-form-radio-group
v-model="question_option"
:options="item.qOptions"
:name="index.toString()"
stacked
/>
</b-form-group>
<b-card-text class="mt-1 mb-0">
<p><b>Hints:</b> <span v-if="question_option !== ''" v-html="item.hints"></span></p>
</b-card-text>
</li>
</ul>
If I select one radio option then it gets selected in every radio group.
I want to select just one radio item by click. How can I solve this problem?