Wizard in dialog cant reset wizard each time open the dialog

UI Components for JSF
Post Reply
Ensky
Posts: 2
Joined: 10 Mar 2015, 11:57

27 Mar 2015, 09:56

Hi
I use PF 5.1 / Java 8 / tomcat 8 / prostgreSQL 9.3 I have a data modify screen where data is loaded to a table then click a button opens a dialog, inside the dialog there is a wizard. my problem is first i open one and go to last step of the wizard and close the dialog then i open another dialog but i still get the interface of last dialog i opened. i have tried many ways on the net didn't work any advice appreciated

Code: Select all

	<p:column style="width:15%; text-align: center" headerText="Edit">
							<p:commandButton onstart="PF('Dialog').show()" 
								update=":form:grid, :form:grid_prd" icon="ui-icon-pencil"
								title="Modify" value="Modify">
								<f:setPropertyActionListener value="#{CrNoteHeader}"
									target="#{ModifyCrNoteBean.selectedHedObj}" />

							</p:commandButton>


this is the button i use to open the dialog

Code: Select all

<p:dialog header="Credit Note Information" widgetVar="Dialog"
						modal="false" showEffect="clip" hideEffect="clip"
						resizable="false" minimizable="true" closeOnEscape="true"
						draggable="true" height="500" width="975">

						<p:wizard  flowListener="#{ModifyCrNoteBean.onFlowProcess}">

							<p:tab id="general" title="General" style="border:none">
								<h:outputLabel value="Customer Name:* " />

							<p:inputText id="name" value="#{ModifyCustomerBean.customerName}"
								validatorMessage="Name Max Limit Exceeded - Max Limit is 20 Characters">
								<f:validateLength maximum="20" for="name" />
							</p:inputText>

							<p:spacer width="30" />

							<h:outputLabel value="Phone Mobile * " />
							<p:inputText id="pMobile" value="#{ModifyCustomerBean.phnMobile}">
							</p:inputText>

							<h:outputLabel for="country" value="Country " />
							<p:selectOneMenu id="country"
								value="#{ModifyCustomerBean.selectdCntryId}"
								style="width:70%">
								<p:ajax listener="#{ModifyCustomerBean.onCountryChange}" />
								<f:selectItem itemLabel="Select" itemValue="" />
								<f:selectItems value="#{ModifyCustomerBean.countryList}"
									var="obj" itemLabel="#{obj.countryName}"
									itemValue="#{obj.countryId}" />
							</p:selectOneMenu>

							<p:spacer width="30" />

							<h:outputLabel value="Phone Office " />
							<p:inputText id="pOffice" value="#{ModifyCustomerBean.phnOffice}">
							</p:inputText>

							<h:outputLabel value="City " />
							<p:inputText id="city" value="#{ModifyCustomerBean.city}">
							</p:inputText>

							<p:spacer width="30" />

							<h:outputLabel value="Skype " />
							<p:inputText id="skypeid" value="#{ModifyCustomerBean.skypeId}">
							</p:inputText>

							<h:outputLabel value="Email " />
							<p:inputText id="email" value="#{ModifyCustomerBean.email}">
							</p:inputText>

							<p:spacer width="30" />

							<h:outputLabel value="Viber" />
							<p:inputText id="viberid" value="#{ModifyCustomerBean.viberId}">
							</p:inputText>

							<h:outputLabel value="NIC/PP/DR " />
							<p:inputText id="nic" value="#{ModifyCustomerBean.nic}">
							</p:inputText>

							<p:spacer width="30" />

							<h:outputLabel for="maxCrLmt" value="Max. Cr. Limit " />
							<p:inputText id="maxCrLmt"
								disabled="#{ModifyCustomerBean.disabledMaxCrLmit}"
								value="#{ModifyCustomerBean.maxCrLimit}"
								validatorMessage="Max. Cr. Limit Max Limit Exceeded - Max Limit is 15">
								<f:validateLength maximum="15" />
							</p:inputText>

							<h:outputLabel value="Address * " />
							<p:inputTextarea rows="3" cols="30" style="width:97%"
								value="#{ModifyCustomerBean.custAddress}" maxlength="200"
								autoResize="false" />

							<f:facet name="footer">
								<p:commandButton value="Edit" icon="ui-icon-check"
									actionListener="#{ModifyCustomerBean.editCustomer}"
									update="panel,growl" style="margin:0"
									oncomplete="Dialog.hide()" />
								<p:spacer width="20" height="20" />
								<p:commandButton value="Cancel" icon="ui-icon-check"
									actionListener="#{ModifyCustomerBean.editCancel}"
									update="panel,growl" style="margin:0"
									oncomplete="Dialog.hide()" />
							</f:facet>
						</p:panelGrid>
							</p:tab>

							<p:tab id="Additional" title="Additional Details">
								//............................
									
							</p:tab>

							<p:tab id="confirm" title="Confirmation">
//...................
							</p:tab>
						</p:wizard>

Post Reply

Return to “PrimeFaces”

  • Information
  • Who is online

    Users browsing this forum: No registered users and 27 guests