diff --git a/src/api/course/course.js b/src/api/course/course.js index 9433ed2..5665890 100644 --- a/src/api/course/course.js +++ b/src/api/course/course.js @@ -44,6 +44,7 @@ export function deleteCourse (params) { // 查询课程列表 export function getCourseList (params) { + if(params.tag) params.tag = params.tag.toString(); return request({ url: courseApi.list, method: 'get', diff --git a/src/views/course/CourseList.vue b/src/views/course/CourseList.vue index ce41fdb..a2fddfb 100644 --- a/src/views/course/CourseList.vue +++ b/src/views/course/CourseList.vue @@ -42,7 +42,7 @@ export default { data() { return { dictCourseTag: [], - queryParam: { courseName: this.$route.query.courseName || '' }, + queryParam: { courseName: this.$route.query.courseName || '', tag: [] }, queryOptions: [ { type: 'input', placeholder: '课程名称', key: 'courseName' }, { type: 'select-dic-tree', placeholder: '请选择课程类别', key: 'courseType' , options: [] }, @@ -56,6 +56,7 @@ export default { columns: [ { title: '课程编号', width: '160px', align: 'center', dataIndex: 'courseCode', key: 'courseCode' }, { title: '课程名称', width: 'auto', align: 'center', dataIndex: 'courseName', key: 'courseName' }, + { title: '课程类别', width: 'auto', align: 'center', dataIndex: 'courseType', key: 'courseType' }, { title: '课时/分', width: '160px', align: 'center', dataIndex: 'hour', key: 'hour' }, { title: '数量', width: '160px', align: 'center', dataIndex: 'questionCount', key: 'questionCount' }, { title: '操作', key: 'operation', width: '300px', align: 'center', scopedSlots: { customRender: 'action' } }, @@ -78,6 +79,8 @@ export default { //课程标签字典 dictionaryDropDown({ dictionaryCode: '0008' }).then((res) => { this.queryOptions[2].options = res.data + + }) }, handleRefresh() {