N°3786 - Add pause at the end of the page unload async request to follow the guideline used in N°2763

This commit is contained in:
Molkobain
2021-07-16 20:02:04 +02:00
parent 68f3c53faa
commit e15953524a
2 changed files with 19 additions and 1 deletions

View File

@@ -115,10 +115,11 @@ function OnUnload(sTransactionId, sObjClass, iObjKey, sToken)
// IMPORTANT: the ajax request MUST BE synchronous to be executed in this context
$.ajax({
url: GetAbsoluteUrlAppRoot()+'pages/ajax.render.php',
async: false,
async: true,
method: 'POST',
data: {operation: 'on_form_cancel', transaction_id: sTransactionId, obj_class: sObjClass, obj_key: iObjKey, token: sToken }
});
CombodoGlobalToolbox.Pause(1000);
}
}