zhongshujie
2024-12-20 32986b54a0e2661f7ad6ed79f3ef12c4289eace9
packageCourse/pages/course/detail/index.js
@@ -26,6 +26,8 @@
    },
    courseLoading: true,
    classLoading: false,
    showContentOnly: false,
    reason: '',
    // 加载参数
    bottomLoading: false,
    isMoreData: false,
@@ -49,6 +51,24 @@
      title: '基本信息',
    })
    this.getData()
  },
  showDialog(e) {
    const {
      item
    } = e.currentTarget.dataset;
    const str = item.reason ? item.reason : '-'
    this.setData({
      showContentOnly: true,
      reason: str
    });
  },
  closeDialog() {
    this.setData({
      showContentOnly: false
    });
  },
  // 获取课程信息
@@ -354,14 +374,17 @@
      classId,
      item
    } = e.currentTarget.dataset
    if (item.applyState == 'WaitAudit' || item.applyState == 'Reject') {
    if (item.applyState == 'WaitAudit') {
      wx.showToast({
        title: item.applyState == 'WaitAudit' ? '审核中' : '未通过',
        title: '审核中',
        duration: 1000,
        icon: 'none',
      })
      return false
    }
    if (item.applyState == 'Reject') {
      return false
    }
    wx.navigateTo({
      url: '/packageCourse/pages/teachClass/index?classId=' + classId + '&courseId=' + this.data.courseId + '&author=' + this.data.bookData.author + '&isbn=' + this.data.bookData.isbn + '&bookId=' + this.data.bookData.id + '&rootCmsItemId=' + this.data.bookData.rootCmsItemId + "&bookRefCode=" + this.data.defaultCmsPath,
    })