This commit is contained in:
zhaofang
2022-07-21 15:49:59 +08:00
parent c61b435b6a
commit b4f83b1795
9 changed files with 11 additions and 12 deletions

View File

@@ -40,8 +40,8 @@ const pageList = function(query) {
* 课程的详细信息
* @param {String} id
*/
const detail = function(id) {
return ajax.get('/xboe/m/course/portal/detail?id=' + id);
const detail = function(id,preview) {
return ajax.get(`/xboe/m/course/portal/detail?id=${id}&preview=${preview}`);
}
/**

View File

@@ -567,7 +567,7 @@ export default {
},
getDetail() {
let $this = this;
apiCoursePortal.detail(this.id).then(rs => {
apiCoursePortal.detail(this.id,true).then(rs => {
if (rs.status == 200) {
this.courseInfo = rs.result.course;
this.teacherList = rs.result.teachers;

View File

@@ -607,7 +607,7 @@ export default {
this.courseInfo.coverImg = "";
},
getDetail() {
apiCoursePortal.detail(this.id).then(rs => {
apiCoursePortal.detail(this.id,true).then(rs => {
if (rs.status == 200) {
this.courseInfo = rs.result.course;
if(rs.result.course.coverImg !== '') {

View File

@@ -443,7 +443,7 @@ export default {
}
},
getDetail() {
apiCoursePortal.detail(this.manageStudyData.id).then(rs => {
apiCoursePortal.detail(this.manageStudyData.id,true).then(rs => {
if (rs.status == 200) {
let treeList = [];
if (rs.result.sections.length > 0) {
@@ -523,7 +523,7 @@ export default {
});
},
getRecordDetail(id) {
apiCoursePortal.detail(id).then(rs => {
apiCoursePortal.detail(id,true).then(rs => {
if (rs.status == 200) {
let treeList = [];
if (rs.result.sections.length > 0) {

View File

@@ -173,7 +173,7 @@ export default {
let $this=this;
//页面只支取一次,所以先直接写在这里面
apiCoursePortal.detail(id).then(rs=>{
apiCoursePortal.detail(id,false).then(rs=>{
if(rs.status==200){
if(rs.result.teachers && rs.result.teachers.length > 0){
let userIds=[];

View File

@@ -363,7 +363,7 @@ export default {
this.loadResOwners();
let $this = this;
//页面只支取一次,所以先直接写在这里面
apiCoursePortal.detail(id).then(rs => {
apiCoursePortal.detail(id,false).then(rs => {
if (rs.status == 200) {
this.courseInfo = rs.result.course;
if(rs.result.course.tags != '') this.tags = rs.result.course.tags.split(",");

View File

@@ -484,7 +484,7 @@ export default {
this.showQrimage();
let $this = this;
//页面只支取一次,所以先直接写在这里面
apiCoursePortal.detail(id).then(rs => {
apiCoursePortal.detail(id,true).then(rs => {
if (rs.status == 200) {
console.log(rs,'2')
this.courseInfo = rs.result.course;

View File

@@ -300,7 +300,7 @@ export default {
//console.log("播放结束");
},
loadData() {
apiCoursePortal.detail(this.courseId).then(rs=>{
apiCoursePortal.detail(this.courseId,true).then(rs=>{
if(rs.status==200){
//设置必须的字段
rs.result.sections.forEach(sec=>{

View File

@@ -580,10 +580,9 @@ export default {
if(this.contentData.status<9){
this.finishStudyItem();
}
},
loadData() {
apiCoursePortal.detail(this.courseId).then(rs => {
apiCoursePortal.detail(this.courseId,false).then(rs => {
if (rs.status == 200) {
//设置必须的字段
rs.result.sections.forEach(sec => {