闫增涛
2024-05-07 4a9955330070cf8abd78d95aaa2067d9a06a88c3
pages/bibliographyList/index.js
@@ -420,23 +420,9 @@
        Md5: item.datas.freeFile.FileList[0].Md5,
        dialogBox: true
      })
      // wx.showModal({
      //   title: '请输入邮箱',
      //   content: '',
      //   confirmColor: '#ff6c00',
      //   cancelColor: '#949494',
      //   placeholderText: '请输入邮箱号',
      //   editable: true,
      //   complete: (res) => {
      //     if (res.cancel) {
      //       console.log('取消');
      //     }
      //     if (res.confirm) {
      //       this.setData({
      //         input: res.content
      //       })
      //       this.confirmM()
      //     }
      // wx.scanCode({
      //   success: res => {
      //     console.log(res);
      //   }
      // })
    },
@@ -448,6 +434,9 @@
    },
    //提交
    confirmM(e) {
      wx.showLoading({
        title: '发送中...',
      })
      const isEmailValid = /^[a-zA-Z0-9_.-]+@[a-zA-Z0-9-]+(\.[a-zA-Z0-9-]+)*\.[a-zA-Z0-9]{2,6}$/.test(this.data.input);
      if (isEmailValid && this.data.input) {
        this.setData({
@@ -458,6 +447,7 @@
          md5s: [this.data.Md5]
        }
        app.MG.file.sendFileWithEmail(query).then(res => {
          wx.hideLoading()
          if (res) {
            wx.showToast({
              icon: 'success',