html52.com
我爱小程序-开发者交流社区

微信升级为7.0.10后wx.request 400,7.0.09还是好的,什么鬼?

// 微信版本7.0.10  返回400
// 微信版本7.0.09 正常

Tool.exeRequest({
      url:"/api/msys/login",
      data:{'username':value.username,'pwd':value.pwd, 'openid': that.data.openid, 'isbind':that.data.isbind},
      success:function(data){
    }}
//Tool.exeRequest
var that = this;
  var sessionId = that.getCurrentSysUser() ? that.getCurrentSysUser().sessionId : "";
  wx.request({
    url: that.finalData.API_DOMAIN + requestConfig.url,
    data: requestConfig.data ? requestConfig.data : {},
    header: {
      "Cookie": "JSESSIONID=" + sessionId + ";SHAREJSESSIONID=" + sessionId,
      "content-type":"application/x-www-form-urlencoded"
    },
    success: function (res) {
      console.log("asdfasfasdfasdfasdfsd")
      console.log(res)
      console.log("asdfasfasdfasdfasdfsd")
      if (res.data.result == 0 || res.data.success) {
        requestConfig.success ? requestConfig.success(res.data) : "";
      } else {
        if (res.data.msg) {
          that.msg(res.data.msg);
        }
      }
    },
    fail: function (e) {
      console.log("请求失败");
      console.log(e);
      if (requestConfig.fail) {
        requestConfig.fail({ message: "系统繁忙请稍后重试" });
      }
    },
    complete: function () {
      if (requestConfig.complete) {
        requestConfig.complete();
      }
    }
  });

评论 抢沙发

  • 昵称 (必填)
  • 邮箱 (必填)
  • 网址

真正的个人免签约支付接口

云免签H5支付