I have a commandScript that runs when a page loads so that it loads a portion of the page asynchronously:
<o:commandScript name="refreshPowerStatus" action="#{powerBean.refreshPowerStatus}"
render="powerPanel"/>
<h:outputScript target="body">refreshPowerStatus()</h:outputScript>
I'd like this script to also be used every time a power-on/power-off action takes place, so I'm using functionality:
<h:commandButton value="Power On" action="#{powerBean.powerOn}">
<f:ajax execute="@this" render="@form"/>
<ace:ajax execute="@this" onComplete="refreshPowerStatus()" render="powerPanel"/>
</h:commandButton>
The refreshPowerStatus() call, however, causes the hourglass wait cursor to appear.
Is there a non-CSS hack way of getting this to go away? Or to at least only have the wait cursor to appear over the button that is pressed? There is no wait cursor on page load when its run automatically so I'm wondering if there is something similar I can do.