做问卷调查时,当单选、多选、问答题循环时,获取题目答案可如下:
问卷数据类型
<view class="common-info {
{index !=0?'top-info':''}}" wx:for="{
{list}}" id="{
{item.id}}" wx:key="id">
<view class="question">
<span class="red-star">*</span>
<span>{
{index+1}}. </span>
<span>{
{ item.question}}</span>
</view>
<view class="enter-info">
<!-- 单选框 -->
<view class="question-radios" wx:if="{
{item.type == 1}}" >
<radio-group bindchange="dataChange" data-index="{
{index}}" data-ans="{
{item.ans}}">
<label class="question-radio-item" wx:for="{
{item.selectList}}" wx:for