收藏
回答

getwxacodeunlimit 接口scene参数可以直接拼接到path里吗?

scene 必须配合前端来接收吗, 可以扫码后直接拼接到小程序地址中吗?每次都需要前端来配合接收 太麻烦啦~

回答关注问题邀请回答
收藏

13 个回答

  • 胃里养了只霸王龙
    胃里养了只霸王龙
    2024-08-26
    if (!options.scene) {
        this.setData({
          partJobId: options.partJobId || app.globalData.query.partJobId || ''
        })
      } else {
      let getQueryString = {}
      const strs = decodeURIComponent(options.scene).split('&') //以&分割
      //取得全部并赋值
      for (var i = 0; i < strs.length; i++) {
        getQueryString[strs[i].split('=')[0]] = unescape(strs[i].split('=')[1])
      }
      this.setData({
        partJobId: getQueryString['partJobId'] || ''
      })
    }
    
    2024-08-26
    有用
    回复
  • 一笑皆春
    一笑皆春
    2024-08-26

    不可以,scene就是单独的参数让你传的,小程序中拿数据也只认scene参数

    2024-08-26
    有用
    回复
  • จุ๊บ
    จุ๊บ
    2024-08-26

    不可以的。只能放在scene里面,你可以让前端根据 后端 scene的写法,自定义编译去调试

    2024-08-26
    有用
    回复

正在加载...

登录 后发表内容