zs
litian
2024-09-20 fba71ba1ae5030cb1a20f54f29fb06ad97060297
pages/home/home.js
@@ -45,8 +45,11 @@
    this.setData({
      searchVal: "",
    });
    console.log(this.data.searchVal)
    this.loadHomePage();
    const token = wx.getStorageSync(app.config.tokenKey)
    if (token) {
      this.getShoppingCartList()
    }
  },
  onLoad() {
@@ -72,11 +75,8 @@
          this.init();
        }
      })
    } else {
      this.init();
      this.registe()
    }
    this.init();
  },
  onReachBottom() {},
  onPullDownRefresh() {
@@ -453,7 +453,6 @@
    //   duration: 1000
    // })
    const item = e.currentTarget.dataset.book
    console.log(item);
    // 网页类型跳转到网址复制页,因为url传参不能传 带参数的网络地址,所以此处要把网络地址里的传参摘出来,放到url里
    let urlData = ''
    const flags = item.jsek_link.indexOf("?")
@@ -539,7 +538,7 @@
          )
        ) {
          wx.showToast({
            title: "该书已在购物车,请勿重复添加空",
            title: "该商品已在购物车,请勿重复添加",
            icon: 'none',
            duration: 1000
          })