richfaces - MyFaces 4.0.2 does not always seem to know what the source of the ajax event was - Stack Overflow

admin2025-04-16  5

I'm using MyFaces with a heavily altered version of RichFaces to support Jakarta. That could be an issue but I think the issue lies within MyFaces. In RichFaces we receive the ajax events that are registered with faces.ajax.addOnEvent(facesEventsListener);. When I receive the event it is common to use the received data to get the source of the event.

const statusAjaxEventHandler = function (data, methodName) {
  ...
  const source = data.source;
  ...
}

But that source is now null and so the event can't be linked to the correct element. This happens when the page is rendered through ajax. A full page reload allows the source to be found.

Any help is very much appreciated.

MAG, Milo

And for those who like to use RichFaces with Jakarta: and in branch 'jakarta'

转载请注明原文地址:http://anycun.com/QandA/1744802341a87822.html