question img

This commit is contained in:
caoqianming 2020-06-04 21:33:16 +08:00
parent 7af86c34b2
commit ffbaaf6549
8 changed files with 25 additions and 3 deletions

View File

@ -30,6 +30,13 @@ Page({
onLoad: function () {
var that = this
api.request('/crm/consumer/collects/', 'GET').then(res => {
for(var i=0;i<res.data.length;i++){
if(res.data[i].img){
res.data[i].img = getApp().globalData.mediahost + res.data[i].img
}
}
that.data.sctms = res.data
that.setData({
tmtotal:res.data.length

View File

@ -10,6 +10,7 @@
<span style="color:drakblue;font-weight:bold;font-size:14px">{{tm_current.questioncat_name}}</span>
</view>
<view class="weui-article__title">{{tm_current.name}}</view>
<view wx:if="{{tm_current.img}}" style="text-align:center"><image src="{{tm_current.img}}" mode="aspectFit"></image></view>
</view>
<view class="weui-cells weui-cells_radio">
<radio-group class="radio-group" bindchange="radioChange" wx:if="{{(tm_current.type=='单选' ||tm_current.type=='判断')}}">

View File

@ -19,6 +19,7 @@
)
</view>
<view class="weui-article__title">{{currentTm.name}}</view>
<view wx:if="{{currentTm.img}}" style="text-align:center"><image src="{{currentTm.img}}" mode="aspectFit"></image></view>
</view>
<view class="weui-cells weui-cells_radio">
<radio-group class="radio-group" bindchange="radioChange" wx:if="{{(currentTm.type=='单选' ||currentTm.type=='判断')}}">

View File

@ -17,6 +17,11 @@ Page({
var that = this
var query = {'examtest':options.id}
api.request('/examtest/answerdetail/', 'GET', query).then(res => {
for (var i = 0; i < res.data.length; i++) {
if(res.data[i].img){
res.data[i].img = getApp().globalData.mediahost + res.data[i].img
}
}
that.data.results= res.data
that.showTm(0)
that.setData({

View File

@ -7,6 +7,7 @@
<span class="txlabel">{{tm_current.question.type}}</span>
</view>
<view class="weui-article__title">{{tm_current.question.name}}</view>
<view wx:if="{{tm_current.img}}" style="text-align:center"><image src="{{tm_current.img}}" mode="aspectFit"></image></view>
</view>
<view class="weui-cells weui-cells_radio">
<radio-group class="radio-group" wx:if="{{(tm_current.question.type=='单选' ||tm_current.question.type=='判断')}}">

View File

@ -30,6 +30,11 @@ Page({
var value = wx.getStorageSync('examtest')
console.log(value)
if (value) {
for(var i=0;i<value.questions.length;i++){
if(value.questions[i].img){
value.questions[i].img = getApp().globalData.mediahost + value.questions[i].img
}
}
that.data.examtest = value
that.data.tms = value.questions
that.setData({

View File

@ -17,6 +17,7 @@
<span style="color:gray">({{tm_current.questioncat_name}})</span>
</view>
<view class="weui-article__title">{{tm_current.name}}</view>
<view wx:if="{{tm_current.img}}" style="text-align:center"><image src="{{tm_current.img}}" mode="aspectFit"></image></view>
</view>
<view class="weui-cells weui-cells_radio">
<radio-group class="radio-group" bindchange="radioChange" wx:if="{{(tm_current.type=='单选' ||tm_current.type=='判断')}}">

View File

@ -11,8 +11,6 @@
"newFeature": true,
"coverView": true,
"autoAudits": false,
"showShadowRootInWxmlPanel": true,
"scopeDataCheck": false,
"checkInvalidKey": true,
"checkSiteMap": true,
"uploadWithSourceMap": true,
@ -20,7 +18,10 @@
"ignore": [],
"disablePlugins": [],
"outputPath": ""
}
},
"showShadowRootInWxmlPanel": true,
"scopeDataCheck": false,
"useCompilerModule": false
},
"compileType": "miniprogram",
"libVersion": "2.10.3",