123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139 |
- <wxs module="filter" src="../../../wxs/exam-fun.wxs"></wxs>
- <view class="exam-page p10">
- <view class="view-wrap">
- <view class="exam-count-down">{{remainTimeStr}}</view>
- </view>
- <view class="view-wrap-hidden">
- </view>
- <i-panel i-class="exam-panel-title">
- <i-cell-group i-class="exam-cell">
- <!-- 单选题 -->
- <i-cell wx:if="{{item.type==2}}">
- <view>
- <rich-text nodes="{{item.index+1}}、[单]{{item.title}}" />
- <radio-group class="radio-answer" bindchange="radioChange" data-index="{{index}}">
- <label class="radio" wx:for="{{preList}}" wx:for-item="answer" wx:key="anserIndex" wx:if="{{item['answer'+(index+1)]}}">
- <view class="radio-answer">
- <radio color="#2d8cf0" value="{{index+1}}" checked="{{item.select==index+1}}">
- {{answer}}. {{item['answer'+(index+1)]}}
- </radio>
- </view>
- </label>
- </radio-group>
- </view>
- </i-cell>
- <!-- 多选题 -->
- <i-cell wx:if="{{item.type==3}}">
- <view>
- <rich-text nodes="{{item.index+1}}、 [多]{{item.title}}"></rich-text>
- <checkbox-group class="checkbox-answer" style="margin-top:10rpx" bindchange="checkboxChange">
- <label class="checkbox" wx:for="{{preList}}" wx:key="index" wx:for-item="answer" wx:if="{{item['answer'+(index+1)]}}">
- <view class="checkbox-answer">
- <checkbox color="#2d8cf0" value="{{index+1}}" checked="{{filter.isSelect( index+1, item.select)}}">
- {{answer}}. {{item['answer'+(index+1)]}}
- </checkbox>
- </view>
- </label>
- </checkbox-group>
- </view>
- </i-cell>
- <!-- 判断 -->
- <i-cell wx:if="{{item.type==1}}">
- <view>
- <rich-text nodes="{{item.index+1}}、[判]{{item.title}}" />
- <radio-group class="radio-answer" bindchange="radioChange" data-index="{{index}}">
- <label class="radio" wx:for="{{2}}" wx:for-item="answer">
- <view class="radio-answer">
- <radio color="#2d8cf0" value="{{index+1}}" checked="{{item.select==index+1}}">
- {{preList[index]}}. {{item['answer'+(index+1)]}}
- </radio>
- </view>
- </label>
- </radio-group>
- </view>
- </i-cell>
- <i-cell wx:if="{{item.type==4}}">
- <view>
- <rich-text nodes="{{item.index+1}}、[案例]{{item.title}}" />
- <i-cell-group i-class="exam-cell" wx:for="{{item.child}}" wx:for-item="child" wx:key="answerId" wx:for-index="cid">
- <!-- 案例单选题 -->
- <i-cell wx:if="{{child.type==2}}">
- <view>
- <rich-text nodes="{{cid+1}}、[单]{{child.title}}" />
- <radio-group class="radio-answer" bindchange="radioChange" data-index="{{index}}" data-cid="{{cid}}">
- <label class="radio" wx:for="{{preList}}" wx:for-item="answer" wx:key="anserIndex" wx:if="{{child['answer'+(index+1)]}}">
- <view class="radio-answer">
- <radio color="#2d8cf0" value="{{index+1}}" checked="{{child.select==index+1}}">
- {{answer}}. {{child['answer'+(index+1)]}}
- </radio>
- </view>
- </label>
- </radio-group>
- </view>
- </i-cell>
- <!-- 案例多选题 -->
- <i-cell wx:if="{{child.type==3}}">
- <view>
- <rich-text nodes="{{cid+1}}、 [多]{{child.title}}"></rich-text>
- <checkbox-group class="checkbox-answer" style="margin-top:10rpx" data-cid="{{cid}}" bindchange="checkboxChange">
- <label class="checkbox" wx:for="{{preList}}" wx:key="index" wx:for-item="answer" wx:if="{{child['answer'+(index+1)]}}">
- <view class="checkbox-answer">
- <checkbox color="#2d8cf0" value="{{index+1}}" checked="{{filter.isSelect( index+1, child.select)}}">
- {{answer}}. {{child['answer'+(index+1)]}}
- </checkbox>
- </view>
- </label>
- </checkbox-group>
- </view>
- </i-cell>
- <!-- 案例判断 -->
- <i-cell wx:if="{{child.type==1}}">
- <view>
- <rich-text nodes="{{cid+1}}、[判]{{child.title}}" />
- <radio-group class="radio-answer" bindchange="radioChange" data-index="{{index}}" data-cid="{{cid}}">
- <label class="radio" wx:for="{{2}}" wx:for-item="answer">
- <view class="radio-answer">
- <radio color="#2d8cf0" value="{{index+1}}" checked="{{child.select==index+1}}">
- {{preList[index]}}. {{child['answer'+(index+1)]}}
- </radio>
- </view>
- </label>
- </radio-group>
- </view>
- </i-cell>
- </i-cell-group>
- </view>
- </i-cell>
- </i-cell-group>
- <view class="tc">
- <button type="primary" size="mini" bindtap='nextAnswer'>下一题</button>
- <button type="primary" size="mini" bindtap='dosubmit' class="ml20">交卷</button>
- </view>
- </i-panel>
- </view>
- <view class="bg-white p20">
- <i-row>
- <i-col wx:for="{{info.answers}}" style="float:left;width:12%;text-align:center" wx:key="item.id">
- <view class="item-select {{filter.isExamSelect(index, info)}} " bindtap="selectquestion" data-index="{{index}}"> {{index+1}} </view>
- </i-col>
- </i-row>
- </view>
- <i-modal title="考试结果" visible="{{modalShow}}" bind:ok="returnRecord" bind:cancel="returnRecord">
- <view>我的战绩:{{score}}分 </view>
- </i-modal>
- <i-action-sheet visible="true" visible="{{timeOutShow}}" mask-closable="{{ false }}">
- <view slot="header" style="padding: 16px">
- <view class="exam-timeout-title">考试试卷结束,请提交试卷!</view>
- <button class="i-btn i-btn-primary i-btn-square" bindtap='dosubmit'>提交</button>
- </view>
- </i-action-sheet>
|