js ajax请求传token方法一:headers: { Authorization: "BasicAuth " + token }方法二:beforeSend: function (xhr) { xhr.setRequestHeader('Authorization', 'BasicAuth ' +token); }