|
|
@@ -1,6 +1,6 @@
|
|
|
<template>
|
|
|
<v-container>
|
|
|
- <v-card-title>已选题目</v-card-title>
|
|
|
+ <v-card-title class="display-1 mb-4">已选题目</v-card-title>
|
|
|
<v-data-table
|
|
|
item-key="id"
|
|
|
:headers="selectedHeaders"
|
|
|
@@ -33,22 +33,29 @@
|
|
|
<v-btn class="primary mx-2" @click="onSubmitManualPaper">确认调整</v-btn>
|
|
|
<v-btn class="secondary mx-2" @click="onLeave">返回</v-btn>
|
|
|
</v-row>
|
|
|
- <v-row class="mx-2 mt-5" align="center">
|
|
|
+ <v-card-title class="display-1 text-center">试题列表</v-card-title>
|
|
|
+ <v-row class="mx-2" align="center" justify="space-between">
|
|
|
<v-col cols="3">
|
|
|
<v-text-field v-model="stem" label="根据题目内容查找"></v-text-field>
|
|
|
</v-col>
|
|
|
<v-col cols="3">
|
|
|
- <v-text-field v-model="tags" label="标签"></v-text-field>
|
|
|
+ <v-text-field
|
|
|
+ v-model="tags"
|
|
|
+ label="标签"
|
|
|
+ :disabled="true"
|
|
|
+ ></v-text-field>
|
|
|
</v-col>
|
|
|
<v-col cols="3">
|
|
|
- <v-text-field v-model="knowledgeName" label="知识点"></v-text-field>
|
|
|
+ <v-text-field
|
|
|
+ v-model="knowledgeName"
|
|
|
+ label="知识点"
|
|
|
+ :disabled="true"
|
|
|
+ ></v-text-field>
|
|
|
</v-col>
|
|
|
<v-col cols="1">
|
|
|
<v-btn class="primary mb-4 info" @click="onSearch">搜索</v-btn>
|
|
|
</v-col>
|
|
|
</v-row>
|
|
|
-
|
|
|
- <v-card-title>试题列表</v-card-title>
|
|
|
<v-data-table
|
|
|
v-model="selectedQuestions"
|
|
|
item-key="id"
|
|
|
@@ -56,6 +63,7 @@
|
|
|
:headers="headers"
|
|
|
:items="questions"
|
|
|
show-expand
|
|
|
+ :expanded.sync="expanded"
|
|
|
class="text-wrap"
|
|
|
:loading="loading"
|
|
|
@item-selected="onSelectQuestion"
|
|
|
@@ -69,13 +77,16 @@
|
|
|
</td>
|
|
|
</template>
|
|
|
</v-data-table>
|
|
|
- <v-pagination
|
|
|
- total-visible="5"
|
|
|
- class="my-2"
|
|
|
- :length="Math.ceil(totalNum / pageSize)"
|
|
|
- v-model="pageNum"
|
|
|
- @input="changePage"
|
|
|
- ></v-pagination>
|
|
|
+ <v-row justify="center">
|
|
|
+ <v-col cols="4" align-self="center"
|
|
|
+ ><v-pagination
|
|
|
+ class="my-2"
|
|
|
+ :length="Math.ceil(totalNum / pageSize)"
|
|
|
+ v-model="pageNum"
|
|
|
+ @input="changePage"
|
|
|
+ ></v-pagination
|
|
|
+ ></v-col>
|
|
|
+ </v-row>
|
|
|
<v-snackbar v-model="selectQuestionsSuccess" top color="info">
|
|
|
设置试题成功
|
|
|
</v-snackbar>
|
|
|
@@ -120,6 +131,7 @@ export default Vue.extend({
|
|
|
totalNum: 0,
|
|
|
loading: true,
|
|
|
selectQuestionsSuccess: false,
|
|
|
+ expanded: [] as Array<Question>,
|
|
|
headers: [
|
|
|
{ text: '题目类型', value: 'typeText' },
|
|
|
{ text: '关键词', value: 'keyPoints', sortable: false },
|
|
|
@@ -158,6 +170,7 @@ export default Vue.extend({
|
|
|
return { ...val, typeText: questionTypeToText(val.type), score: 5 }
|
|
|
})
|
|
|
this.totalNum = data.result.totalNum
|
|
|
+ this.expanded = this.questions
|
|
|
this.loading = false
|
|
|
})
|
|
|
},
|