|
|
@@ -581,6 +581,7 @@ import {
|
|
|
getSort,
|
|
|
getUserCourseVideo,
|
|
|
getVideoListByCourseId,
|
|
|
+ getPublicVideoListByCourseId,
|
|
|
getVideoListByCourseIdAll,
|
|
|
sortCourseVideo,
|
|
|
updates,
|
|
|
@@ -601,6 +602,12 @@ import { getConfigByKey } from '@/api/system/config'
|
|
|
export default {
|
|
|
name: "userCourseCatalog",
|
|
|
components: {VideoUpload, QuestionBank, CourseWatchComment, CourseProduct, draggable},
|
|
|
+ props: {
|
|
|
+ usePublicVideoLibrary: {
|
|
|
+ type: Boolean,
|
|
|
+ default: false
|
|
|
+ }
|
|
|
+ },
|
|
|
watch:{
|
|
|
// 深度监听 rules 数组的变化,以更新总权重
|
|
|
"form.randomRedPacketRulesArr": {
|
|
|
@@ -1150,7 +1157,8 @@ export default {
|
|
|
},
|
|
|
getList() {
|
|
|
this.loading = true;
|
|
|
- getVideoListByCourseId(this.queryParams).then(response => {
|
|
|
+ const api = this.usePublicVideoLibrary ? getPublicVideoListByCourseId : getVideoListByCourseId;
|
|
|
+ api(this.queryParams).then(response => {
|
|
|
this.userCourseVideoList = response.rows;
|
|
|
this.total = response.total;
|
|
|
this.loading = false;
|