|
@@ -27,11 +27,12 @@
|
|
|
<div class="part-filter-form">
|
|
|
<el-form class="part-filter-form" :inline="true" :model="filter">
|
|
|
<el-form-item label="题型">
|
|
|
- <question-type-select
|
|
|
- v-model="filter.questionType"
|
|
|
- :disabled="disabledQuestionType"
|
|
|
+ <source-detail-select
|
|
|
+ v-model="filter"
|
|
|
+ :course-id="filter.courseId"
|
|
|
+ :disabled="disabledSourceDetail"
|
|
|
>
|
|
|
- </question-type-select>
|
|
|
+ </source-detail-select>
|
|
|
</el-form-item>
|
|
|
<el-form-item label="题目内容">
|
|
|
<el-input
|
|
@@ -75,10 +76,7 @@
|
|
|
<span>{{ scope.row.course.name }}</span>
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
- <el-table-column label="题型" width="100">
|
|
|
- <template slot-scope="scope">
|
|
|
- <span>{{ scope.row.questionType | questionType }}</span>
|
|
|
- </template>
|
|
|
+ <el-table-column label="题型" prop="sourceDetailName" width="100">
|
|
|
</el-table-column>
|
|
|
<el-table-column label="难度" prop="difficulty" width="80">
|
|
|
</el-table-column>
|
|
@@ -147,10 +145,7 @@
|
|
|
<span>{{ scope.row.course.name }}</span>
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
- <el-table-column label="题型" width="100">
|
|
|
- <template slot-scope="scope">
|
|
|
- <span>{{ scope.row.questionType | questionType }}</span>
|
|
|
- </template>
|
|
|
+ <el-table-column label="题型" prop="sourceDetailName" width="100">
|
|
|
</el-table-column>
|
|
|
<el-table-column label="难度" prop="difficulty" width="80">
|
|
|
</el-table-column>
|
|
@@ -198,11 +193,16 @@ export default {
|
|
|
type: [String, Number],
|
|
|
default: "",
|
|
|
},
|
|
|
- questionType: {
|
|
|
- type: String,
|
|
|
- default: "",
|
|
|
+ sourceDetail: {
|
|
|
+ type: Object,
|
|
|
+ default() {
|
|
|
+ return {
|
|
|
+ questionType: "",
|
|
|
+ sourceDetailId: "",
|
|
|
+ };
|
|
|
+ },
|
|
|
},
|
|
|
- disabledQuestionType: {
|
|
|
+ disabledSourceDetail: {
|
|
|
type: Boolean,
|
|
|
default: false,
|
|
|
},
|
|
@@ -225,6 +225,7 @@ export default {
|
|
|
filter: {
|
|
|
courseId: "",
|
|
|
questionType: "",
|
|
|
+ sourceDetailId: "",
|
|
|
questionBody: "",
|
|
|
questionProperty: [],
|
|
|
},
|
|
@@ -241,8 +242,11 @@ export default {
|
|
|
},
|
|
|
methods: {
|
|
|
initData() {
|
|
|
- this.filter.courseId = this.courseId;
|
|
|
- this.filter.questionType = this.questionType;
|
|
|
+ this.filter = Object.assign({}, this.filter, {
|
|
|
+ courseId: this.courseId,
|
|
|
+ ...this.sourceDetail,
|
|
|
+ });
|
|
|
+
|
|
|
this.curSelectedQuestions = [];
|
|
|
this.curSelectedQuestionIds = [];
|
|
|
this.toPage(this.currentPage);
|