Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

求教在ajaxGlobalEvents.send的全局事件下如何设置统一headers信息 #69

Closed
sayll opened this issue Aug 31, 2016 · 2 comments

Comments

@sayll
Copy link

sayll commented Aug 31, 2016

rt

@RubyLouvre
Copy link
Owner

var globalHeader = { xxx: 'yyy', kk: '333'}
avalon.ajaxGlobalEvents.send = function ( promise){
    for(var i in globalHeader){
        promise.setRequestHeader(i, globalHeader[i])
   }
}

// avalon.ajax 

@sayll
Copy link
Author

sayll commented Aug 31, 2016

嗯嗯。谢谢啦

@sayll sayll closed this as completed Aug 31, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants