master
lion 2 months ago
parent 0258d29d07
commit 78b1363942

@ -41,8 +41,18 @@
</el-option>
</el-select>
</div>
<div>
<el-input v-model="select.course_name" placeholder="请输入课程名称"></el-input>
<div style="width: 200px;">
<el-select filterable allow-create clearable
v-model="select.course_name"
placeholder="请输入或选择课程名称"
style="width: 100%;">
<el-option
v-for="item in courseOptions"
:key="item.id"
:label="item.name"
:value="item.name">
</el-option>
</el-select>
</div>
<div>
@ -395,6 +405,9 @@
import {
index as indexTypes
} from "@/api/course/courseType.js"
import {
index as courseIndex
} from "@/api/course/index.js"
import {
download
} from "@/utils/downloadRequest";
@ -501,6 +514,7 @@
//
batchUpdateVisible: false,
courseTypeList: [],
courseOptions: [],
list: [],
total: 0,
year_total: 0,
@ -656,6 +670,7 @@
}
this.getList()
this.getCourseType()
this.getCourseList()
},
methods: {
changeSelectType(e, selectName) {
@ -829,6 +844,7 @@
this.select.is_rencai = ''
this.select.address = ''
this.select.page = 1
this.getCourseList()
this.getList()
},
async getList() {
@ -1010,6 +1026,27 @@
})
this.courseTypeList = res.data
},
async getCourseList() {
try {
const res = await courseIndex({
page: 1,
page_size: 999,
filter: [{
key: 'type',
op: 'eq',
value: this.select.course_type || ''
}]
})
if (res && res.data) {
this.courseOptions = res.data
} else {
this.courseOptions = []
}
} catch (error) {
console.error('获取课程列表失败:', error)
this.courseOptions = []
}
},
//
openBatchUpdateModal() {
if (this.seleSchoolmates.length > 0) {
@ -1037,6 +1074,10 @@
this.training_total = 0
this.searyear = ''
}
},
'select.course_type'() {
this.getCourseList()
this.select.course_name = ''
}
}
}

@ -28,9 +28,9 @@ module.exports = {
*/
publicPath: process.env.ENV === 'staging' ? '/admin' : '/admin',
// 测试
outputDir: '/Users/mac/Documents/朗业/2025/s-苏州科技商学院/wx.sstbc.com/public/admin',
// outputDir: '/Users/mac/Documents/朗业/2025/s-苏州科技商学院/wx.sstbc.com/public/admin',
// 正式
// outputDir: '/Users/mac/Documents/朗业/2024/s-苏州科技商学院/wx.sstbc.com/public/admin',
outputDir: '/Users/mac/Documents/朗业/2024/s-苏州科技商学院/wx.sstbc.com/public/admin',
assetsDir: 'static',
css: {
loaderOptions: { // 向 CSS 相关的 loader 传递选项

Loading…
Cancel
Save