Skip to content

Commit

Permalink
https://issues.apache.org/jira/browse/MYFACES-4679:
Browse files Browse the repository at this point in the history
backport of the fixes from 4.0
  • Loading branch information
werpu committed Sep 12, 2024
1 parent e554195 commit 62ecd98
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -233,7 +233,7 @@ _MF_CLS(_PFX_XHR + "_AjaxRequestQuirks", myfaces._impl.xhrCore._AjaxRequest, /**
*/
getFormData:function () {
var formDataDecorator = this._Lang.createFormDataDecorator(jsf.getViewState(this._sourceForm));
if(!this._isBehaviorEvent()) {
if(this._source && !this._isBehaviorEvent()) {
this._AJAXUTIL.appendIssuingItem(this._source, formDataDecorator);
}
return formDataDecorator;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -304,9 +304,9 @@ _MF_CLS(_PFX_XHR + "_AjaxRequest", _MF_OBJECT, /** @lends myfaces._impl.xhrCore.
//now this is less performant but we have to call it to allow viewstate decoration
ret = this._Lang.createFormDataDecorator(new Array());
_AJAXUTIL.encodeSubmittableFields(ret, this._sourceForm, this._partialIdsArray);
if (this._source && myfacesOptions && myfacesOptions.form && !this._isBehaviorEvent())
if (this._source && !this._isBehaviorEvent()) {
_AJAXUTIL.appendIssuingItem(this._source, ret);

}
}
return ret;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,14 +50,15 @@ _MF_CLS(_PFX_XHR+"_FormDataRequest", myfaces._impl.xhrCore._AjaxRequest, {
//just in case the source item is outside of the form
//only if the form override is set we have to append the issuing item
//otherwise it is an element of the parent form
if (this._source && myfacesOptions && myfacesOptions.form && !this._isBehaviorEvent())
if (this._source && !this._isBehaviorEvent()) {
_AJAXUTIL.appendIssuingItem(this._source, ret);
}
} else {
ret = new FormData();
_AJAXUTIL.encodeSubmittableFields(ret, this._sourceForm, this._partialIdsArray);
if (this._source && myfacesOptions && myfacesOptions.form && !this._isBehaviorEvent())
if (this._source && !this._isBehaviorEvent()) {
_AJAXUTIL.appendIssuingItem(this._source, ret);

}
}

return ret;
Expand Down

0 comments on commit 62ecd98

Please sign in to comment.