<view class="option">
  <view class='option-top'>
    <text class=' subtitleColor pink-bg rank'>{{rank}}/{{info.choiceQuestionNum}}</text>
    <text class='gray'>{{info.completeNum}}人已答</text>
  </view>
  <view class='option-title'>{{rank}}.{{info.question}}（{{info.radio==0?"单选":"多选"}}）</view>
  <view class='option-content'>
    <!-- 单选 -->
    <radio-group wx:if='{{info.radio == 0}}' class='list-block' bindchange="setAnswerChecked">
      <label class='align-top item-content label-radio {{info.myAnswer==item.option?"pink-bg":""}} ' wx:for="{{info.choiceOptions}}" wx:key="*this">
        <view class='item-media'>
          <radio class='radio' checked="{{item.checked}}" disabled='{{answerStatus?true:false}}' value="{{item.option}}" color="#EE3A43"  /> {{item.option}}
        </view>
        <view class='item-inner'>
          <view wx:if='{{item.ctype=="text"}}' class='item-text'>{{item.content}}</view>
          <image wx:if='{{item.ctype=="image"}}' style="width: 200rpx; height: 100rpx;" mode="aspectFit" src="{{item.content}}"></image>
        </view>
        <view class='item-after'><text class='{{item.icon}}' wx:if="{{item.icon.length > 0}}"></text></view>
      </label>
    </radio-group>
    <!-- 多选 -->
    <checkbox-group wx:if='{{info.radio == 1}}' class='list-block' bindchange="setAnswerChecked">
      <label class='align-top item-content label-checkbox {{item.checked?"pink-bg":""}} ' wx:for="{{info.choiceOptions}}" wx:key="*this">
        <view class='item-media'>
          <checkbox class='checkbox' checked="{{item.checked}}" disabled='{{answerStatus?true:false}}' value="{{item.option}}" color="#EE3A43"  /> {{item.option}}
        </view>
        <view class='item-inner'>
          <view wx:if='{{item.ctype=="text"}}' class='item-text'>{{item.content}}</view>
          <image
            wx:if='{{item.ctype=="image"}}'
            style="width: 200rpx; height: 100rpx;"
            mode="aspectFit"
            src="{{item.content}}"
          ></image>
        </view>
        <view class='item-after'><text class='{{item.icon}}' wx:if="{{item.icon.length > 0}}"></text></view>
      </label>
    </checkbox-group>
  </view>
</view>
<view class='buttons-row buttons-gutter'>
  <button  class='button button-radius {{answerStatus && rank == 1?"button-light":"button-warn"}}' bindtap='{{!answerStatus?info.myAnswer.length>0?"submitAnswer":"":"changeQuestion"}}' data-rank='{{info.rank-1}}'>{{answerStatus?"上一题":"确认"}}</button>
  <button class='button button-radius {{answerStatus?"button-warn":"button-light"}}' data-mark='next' bindtap='{{answerStatus?info.rank==info.choiceQuestionNum?"complete":"changeQuestion":""}}' data-rank='{{info.rank+1}}'>{{info.rank==info.choiceQuestionNum?"完成":"下一题"}}</button>
</view>
<view class='answer' hidden='{{!answerStatus}}'>
  <view class='font12 subtitleColor'>正确答案:{{info.answer}}</view>
  <view class='font12 answer-detail'>{{info.explain?info.explain:"暂无答案"}}</view>
</view>
<alert show="{{alertStatus}}" _CONFIG_="{{alert}}" bind:close="close" />
