errCode: -404011 cloud function executio
发布于 6 年前 作者 juanlong 13752 次浏览 来自 官方Issues
  • 当前 Bug 的表现(可附上截图)

err Error: errCode: -404011 cloud function execution error | errMsg: cloud.callFunction:fail requestID , cloud function service error code -504002, error message Function not found: [getWXContext]; at cloud.callFunction api;

  • 预期表现
  • 复现路径
isMatchAdmin (cb) {
    Cloud.getUserInfo()
      .then((resInfo) => {
        const OPENID = this.OPENID = resInfo.result.OPENID
        console.log(OPENID)
        cb && cb()
        Cloud.getAdminList({ db: this.db })
          .then((res) => {
            if (res.data) {
              let isAdmin = false
              res.data.forEach((item) => {
                if (item.openId === OPENID) {
                  isAdmin = true
                }
              })
              this.setData({
                isAdmin: isAdmin
              })
            } else {
              throw new Error()
            }
          })
      })
      .catch(err => {
        console.log('err', err)
        // this.goError()
      })
  },
  • 提供一个最简复现 Demo

err Error: errCode: -404011 cloud function execution error | errMsg: cloud.callFunction:fail requestID , cloud function service error code -504002, error message Function not found: [getWXContext]; at cloud.callFunction api;

1 回复

你好,建议具体描述一下问题

回到顶部