bug
闫增涛
2024-09-07 02eb8d0829a78a30bdb6ce25f93858dfdd61c4dc
packageBookService/pages/bookServices/detail/index.js
@@ -1,6 +1,7 @@
// pages/bookServices/detail/index.js
import Toast from "tdesign-miniprogram/toast";
import tool from "../../../../assets/js/toolClass";
import moment from 'moment'
import {
  loginInfo
} from "../../../../assets/js/login";
@@ -192,19 +193,16 @@
      bookId: options.id + "",
      barHeight: systInfo.statusBarHeight,
      navBarHeight: navBarHeight,
    });
    this.setData({
      options: {
        id: options.id,
        name: options.name,
        name: decodeURI(options.name),
        storeInfo: options.storeInfo,
      },
    });
    wx.setNavigationBarTitle({
      title: options.name,
      title: decodeURI(options.name),
    })
    const token = wx.getStorageSync(app.config.tokenKey)
    let token = wx.getStorageSync(app.config.tokenKey)
    if (!token) {
      loginInfo(app, (data) => {
        if (data) {} else {}
@@ -212,7 +210,7 @@
    }
    this.getBookInfo(options.id);
    // this.getResourceClass(); // 获取资源所属分类
    token = wx.getStorageSync(app.config.tokenKey)
    if (token) {
      this.getShoppingCartProductGet();
      this.getApplyInfo(options.id);
@@ -481,9 +479,7 @@
        }
      }
      this.setData({
        "bookDetail.publicationDate": this.formatDate(
          this.data.bookDetail.publicationDate
        ),
        "bookDetail.publicationDate": moment(this.data.bookDetail.publicationDate).format("YYYY年MM月"),
        "bookDetail.price": this.numFormat(this.data.bookDetail.price),
        "bookDetail.oldPrice": this.numFormat(this.data.bookDetail.oldPrice),
        "bookDetail.paperPrice": this.numFormat(
@@ -719,7 +715,7 @@
      link
    } = e.currentTarget.dataset;
    wx.navigateTo({
      url: `/packageBookService/pages/bookServices/webpage/index?url=${link}`,
      url: `/packageBookService/pages/bookServices/linkPage/index?path=${link}`,
    });
  },
  // tag切换