Skip to content

Commit

Permalink
Fix for TheCoder4eu#750
Browse files Browse the repository at this point in the history
  • Loading branch information
t-oster authored and geopossachs committed Oct 7, 2023
1 parent a9a2964 commit 6203cb7
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion src/main/java/net/bootsfaces/component/ajax/AJAXRenderer.java
Original file line number Diff line number Diff line change
Expand Up @@ -379,7 +379,15 @@ public static boolean generateAJAXCallForASingleEvent(FacesContext context, Clie
jsCallback = "";
}
if (null != rw) {
rw.writeAttribute("on" + keyClientBehavior, jsCallback + script, null);
boolean ajax = ((IAJAXComponent) component).isAjax();
ajax |= null != ((IAJAXComponent) component).getUpdate();
if (!generatedAJAXCall && ajax && "click".equals(keyClientBehavior)) {
//ajax call will be generated later, so skip for now
//see https://github.com/TheCoder4eu/BootsFaces-OSP/issues/750
}
else {
rw.writeAttribute("on" + keyClientBehavior, jsCallback + script, null);
}
}
if (null != code) {
code.append(jsCallback + script);
Expand Down

0 comments on commit 6203cb7

Please sign in to comment.