@esfaenza/extensions 15.2.37 → 15.2.38

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -967,16 +967,17 @@ class MessageService {
967
967
  * @param {Function} postFailure Callback da chimare in caso di fallimento
968
968
  */
969
969
  manageCallResultResponse(response, successMsg, errorMsg, postSuccess = null, postFailure = null) {
970
- if (response.success) {
971
- if (response.haswarning)
972
- this.simpleWarning(response.warning);
970
+ let anyReponse = response;
971
+ if (response.success || anyReponse.Success) {
972
+ if (response.haswarning || anyReponse.HasWarning)
973
+ this.simpleWarning(response.warning || anyReponse.Warning);
973
974
  else if (successMsg)
974
975
  this.simpleSuccess(successMsg);
975
976
  if (postSuccess)
976
977
  postSuccess();
977
978
  }
978
979
  else {
979
- this.simpleError((errorMsg ? errorMsg + ": " : "") + response.haserror ? response.error : '[NO ERR.]');
980
+ this.simpleError((errorMsg ? errorMsg + ": " : "") + (response.haserror || anyReponse.HasError) ? (response.error || anyReponse.Error) : '[NO ERR.]');
980
981
  if (postFailure)
981
982
  postFailure();
982
983
  }