function callExtAjaxRequestBase(url, isJson, headers, params, successfn, showWindow, sync, iswait, errorfn) {
var ajaxConig = {
url: url,
async: sync ? false : true,
method: "POST",
timeout: 600000,//超时时间10min
success: function (response) {
if (!iswait) {
Ext.MessageBox.hide();
}
var d = Ext.decode(response.responseText);
if (d.status == 'Y') {
if (showWindow) {
showExtOKMsgBox(d.msg, successfn);
} else {
successfn(d);
}
} else {
if(errorfn!=null){
errorfn(d);
}
showExtErrorMsgBox(getMsg(d));
}
},
failure: function () {
Ext.MessageBox.hide();
}
};
if (headers) {
ajaxConig.headers = headers;
}
if (isJson) {
ajaxConig.jsonData = params
} else {
ajaxConig.params = params;
}
if (!iswait) {
Ext.MessageBox.wait("系统正在处理中,请稍后.........");
}
Ext.Ajax.request(ajaxConig);
}