this is the code for that update the refresh time for poll
Code: Select all
<h:form prependId="false">
<h:panelGrid columns="2" cellpadding="10">
<h:panelGroup>
<h:outputLabel for="refresh" value="#{msg.label_refresh} " />
<p:spinner id="refresh" value="#{tableroManager.refreshTime}"
min="0" max="999" style="width=30px;" >
<p:ajax update="poll" process="@this" />
</p:spinner>
<h:outputLabel value=" #{msg.label_segundos}" />
</h:panelGroup>
<p:commandButton id="btnPoll" value="#{msg.label_stop}"
actionListener="#{tableroManager.actualizarPoll}"
oncomplete="handlePollStart(xhr, status, args);" widgetVar="btnPoll" process="@this" />
</h:panelGrid>
</h:form>
Code: Select all
<h:form prependId="false">
<p:poll id="poll" interval="#{tableroManager.refreshTime}" actionListener="#{tableroManager.refreshData}"
update="terminales" process="@this" autoStart="true" onerror="poll.stop();" widgetVar="poll"/>
<p:dataGrid var="terminal" value="#{tableroManager.terminales}" columns="13"
paginator="false" effect="true" id="terminales" >
......
......