|
|
|
@ -20,14 +20,14 @@ const router = useRouter() |
|
|
|
|
// console.log(route) |
|
|
|
|
// import { client } from '@/utils/alioss.js' |
|
|
|
|
// 课程列表 |
|
|
|
|
const courseList = ref([]) |
|
|
|
|
const courseList = ref() |
|
|
|
|
// 教师列表 |
|
|
|
|
const teacherList = ref([]) |
|
|
|
|
const teacherList = ref() |
|
|
|
|
const getTeacherList = async () => { |
|
|
|
|
const res = await getTeacherListApi() |
|
|
|
|
console.log(res) |
|
|
|
|
console.log(res, 'teacher') |
|
|
|
|
teacherList.value = res.data |
|
|
|
|
console.log(teacherList.value) |
|
|
|
|
console.log(teacherList.value, 'teacherList.value') |
|
|
|
|
} |
|
|
|
|
const total = ref(0) |
|
|
|
|
const params = ref({ |
|
|
|
@ -45,14 +45,14 @@ const loading = ref(false) |
|
|
|
|
const getCourseList = async () => { |
|
|
|
|
loading.value = true |
|
|
|
|
// console.log(params.value, '11') |
|
|
|
|
if (userStore.userInfo.roleId === 2) { |
|
|
|
|
if (userStore.userInfo.roleId[0] === 2) { |
|
|
|
|
params.value.pageSize = 8 |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
const res = await getCourseListApi(params.value) |
|
|
|
|
courseList.value = res.data.list |
|
|
|
|
total.value = res.data.total |
|
|
|
|
console.log(res.data.list) |
|
|
|
|
console.log(courseList.value, 'courseList.value') |
|
|
|
|
loading.value = false |
|
|
|
|
// console.log(userStore.userName, '1111') |
|
|
|
|
} |
|
|
|
@ -171,7 +171,7 @@ const CloseCouresNameChangeEvent = () => { |
|
|
|
|
<div class="btn"> |
|
|
|
|
<!-- <el-button type="primary" round size="large">全部课程</el-button> |
|
|
|
|
<el-button type="primary" round plain size="large">我的文件夹</el-button> --> |
|
|
|
|
<el-form inline v-if="userStore.userInfo.roleId === 1"> |
|
|
|
|
<el-form inline v-if="userStore.userInfo.roleId[0] === '1'"> |
|
|
|
|
<el-form-item label="课程教师:" class="short-form-item"> |
|
|
|
|
<el-select v-model="params.teacher"> |
|
|
|
|
<el-option |
|
|
|
|