jsf 2 - displaying the input value on confirm dialog returned null -
i working on j2ee6 project extract emails web browserrs. have command button calls extraction method after user entered emails number. once extraction completed confirm dialg shows , displaying number of emails extracted. here xhtml code:
<h:form id="mainform"> <p:panel id="panelform" header="email extractor" > <h:panelgrid id="formulaire" columns="2"> <h:panelgroup id="formblock" layout="block" > <p:panelgrid columns="2"> <p:outputlabel for="emailsnbr" value="enter emails'number:" /> <p:inputtext id="emailsnbr" type="number" requiredmessage="emails number required" value="#{mailmb.number}" required="true" label="emailsnbr"> </p:inputtext> </p:panelgrid> </h:panelgroup> </h:panelgrid> <p:commandbutton value="extract" style="width: 12%;height: 100%" update="tableemails, :confirmpurchase, :confirmpurchasetest, :mainform" id="extractbutton" ajax="true" widgetvar="buttonextract" actionlistener="#{mailmb.searchemails()}" icon="ui-icon-disk" styleclass="ui-priority-primary" onstart="blockuiwidget1.show();" oncomplete=" blockuiwidget1.hide(); if (args && !args.validationfailed) freemails();" /> <p:dialog widgetvar="blockuiwidget1" modal="true" closable="false" > <h:panelgrid columns="2"> <p:graphicimage url="pictures/loading_bar.gif" width="264" height="34" alt="animated-loading-bar"/> <h:outputtext value="please wait..." style="white-space: nowrap;"/> </h:panelgrid> </p:dialog> </p:panel> </h:form> <p:confirmdialog closable="false" style="position: absolute; width: 50px; border-color: blue" id="confirmpurchasetest" message="your database created. , contains #{mailmb.number} emails " appendtobody="true" header="get emails list" severity="info" widgetvar="emailslist"> <h:form> <p:commandbutton id="getemails" style="width: 30%;height: 100%" value="get emails" oncomplete="window.location.href = '/hitonclick/emailslist.xhtml'" > <f:event type="prerenderview" listener="#{mailmb.prerender}"/> </p:commandbutton> <p:commandbutton id="declinetest" style="width: 30%;height: 100%" value="decline" onclick="deletedialog.show();" /> </h:form>
every thing works fine if enter small number. if enter big number exemple 600, extraction time becomes long (it's logic have no problem this) , number displayed on confirm dialog 0 although emails extracted when checked them db. related ajax or what?? how can fix this?
Comments
Post a Comment