question img
This commit is contained in:
parent
117aa8d3bc
commit
e24d67b2cb
|
@ -59,7 +59,7 @@ App({
|
|||
userinfo: {}, // 服务器传回的消费者信息
|
||||
host: 'https://apitest.ahctc.cn',
|
||||
mediahost: 'https://apitest.ahctc.cn',
|
||||
//host: 'http://127.0.0.1:8000',
|
||||
//host: 'http://127.0.0.1:8011',
|
||||
//mediahost: 'http://127.0.0.1:8000',
|
||||
token : '',
|
||||
}
|
||||
|
|
|
@ -5,6 +5,7 @@
|
|||
<view class="weui-article">
|
||||
<view class="weui-article__h2">{{tm_index+1}}.
|
||||
<span class="txlabel">{{tm_current.question.type}}</span>
|
||||
<span style="color:gray">({{tm_current.question.questioncat_name}})</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>
|
||||
|
|
|
@ -23,9 +23,9 @@
|
|||
"disablePlugins": [],
|
||||
"outputPath": ""
|
||||
},
|
||||
"useIsolateContext": true,
|
||||
"useCompilerModule": false,
|
||||
"userConfirmedUseCompilerModuleSwitch": false
|
||||
"userConfirmedUseCompilerModuleSwitch": false,
|
||||
"useIsolateContext": true
|
||||
},
|
||||
"compileType": "miniprogram",
|
||||
"libVersion": "2.10.3",
|
||||
|
|
|
@ -85,13 +85,13 @@ class ExamTestListSerializer(serializers.ModelSerializer):
|
|||
""" Perform necessary eager loading of data. """
|
||||
queryset = queryset.select_related('consumer','paper', 'workscope')
|
||||
return queryset
|
||||
|
||||
from question.serializers import QuestionSerializer
|
||||
class AnswerDetailSerializer(serializers.ModelSerializer):
|
||||
question = QuestionSerializer()
|
||||
class Meta:
|
||||
model = AnswerDetail
|
||||
exclude = ('examtest',)
|
||||
# fields = '__all__'
|
||||
depth = 1
|
||||
|
||||
@staticmethod
|
||||
def setup_eager_loading(queryset):
|
||||
|
@ -130,6 +130,7 @@ class PaperQuestionsDetailSerializer(serializers.ModelSerializer):
|
|||
options = serializers.ReadOnlyField(source='question.options')
|
||||
right = serializers.ReadOnlyField(source='question.right')
|
||||
type = serializers.ReadOnlyField(source='question.type')
|
||||
img = serializers.ReadOnlyField(source='question.img')
|
||||
questioncat_name = serializers.ReadOnlyField(source='question.questioncat.name')
|
||||
level = serializers.ReadOnlyField(source='question.level')
|
||||
class Meta:
|
||||
|
|
Loading…
Reference in New Issue