litian
2024-11-13 e5f0fcb8e803767a2483d21cb1e8b38cb90e7de5
packageDomain/pages/resourceDetails/myVideo/index.js
@@ -232,6 +232,8 @@
      })
      if (this.data.learnClassData) {
        this.getResourceDataList(this.data.learnClassData)
      } else {
        this.resourceDetailsData()
      }
    });
  },
@@ -283,7 +285,6 @@
    app.MG.job.newJobWithApiNewEvent(data).then((res) => {})
  },
  onTabsChange(event) {
    console.log(event, 234)
    let tabValue = event.detail.value
    if (tabValue == '1') {
      this.getNoteList()
@@ -348,7 +349,6 @@
      this.setData({
        isBuy: res.datas.purchasedSaleMethodIdList.includes(res.datas.defaultSaleMethodId)
      })
      console.log(0, res.datas.cmsDatas[0].datas);
      res.datas.cmsDatas[0].datas.forEach((item) => {
        if (this.data.source == 'qrcode') {
          if (item.id == this.data.activeId) {
@@ -370,7 +370,9 @@
            } else {
              // 买了
              if (this.data.buyList.length) {
                if (this.data.buyList.some(citem => item.productLinkPath.includes(citem.productLinkPath))) this.data.threeLeveData.push(item)
                if (this.data.buyList.some(citem => item.productLinkPath.includes(citem.productLinkPath))) {
                  this.data.threeLeveData.push(item)
                }
              } else {
                if (!item.saleMethod.length) {
                  // 没买且无销售方式
@@ -378,7 +380,9 @@
                } else {
                  // 没买且销售方式过期
                  const itemSaleMethod = item.saleMethod.find(citem => citem.SaleType == 'Normal')
                  if (new Date().getTime() > new Date(itemSaleMethod.EndDate).getTime()) this.data.threeLeveData.push(item)
                  if (new Date().getTime() > new Date(itemSaleMethod.EndDate).getTime()) {
                    this.data.threeLeveData.push(item)
                  }
                }
              }
            }
@@ -430,6 +434,7 @@
    })
    if (item.selectType == "video" || item.learnSelectType === "video") {
      if (this.data.formPath === "jsek_cloudLearning") {
        let file =
          item.protectedFile || item.file ? file = item.protectedFile || item.file : file = item.freeFile
        this.setData({
@@ -450,6 +455,7 @@
      md5: md5,
      appRefCode: app.config.appRefCode
    }
    app.MG.file.getAliVod(query).then((res) => {
      if (res) {
        if (res && res.data == '') {
@@ -470,13 +476,15 @@
          videoLoading: false,
        })
      } else {
        return ElMessage.error('无法获取视频资源')
        return wx.showToast({
          icon: 'error',
          title: '无法获取视频资源',
        })
      }
    })
  },
  timeUpdate(e) {
    console.log(2);
    let {
      currentTime,
      duration