After a little bit jsp-debugging I found out that the x:panelTab wich is not active makes no eval of the body. The components in the panelTab-Body will not added to the component tree and will not validated too. I guess it's better to evaluate all components in the body of the panelTab but the rendered-property should be false if the component is not in the active tab.
Can everyone this confirm as a bug??? Regards, Philipp "MyFaces Discussion" <[email protected]> schrieb am 22.04.05 14:20:11: > > The panelTabbedPane has a form built into it so when you click a tab it > submits the form. Your form and button are probably ignored or have odd > behaviour because of nesting. If what you want is to submit both tabs at the > same time then put your button in the tabbedPane component and it will > submit the tabbedPane's form like the tabs do. > > ----- Original Message ----- > From: "Philipp Ahlner" <[EMAIL PROTECTED]> > To: <[email protected]> > Sent: Friday, April 22, 2005 7:48 AM > Subject: panelTabbedPane: Wrong validator behavior > > > > Hi all! > > > > I've two tabs like in the example below. If I press the ok-Button and the > > first tab is shown, the field on the second tab is not validated. > > If I switch to the second Tab and back to the first tab, both fields will > > be validated. It seems the fields are in the component tree after they are > > the first time rendered. Has everyone an idea for a workaround?? > > > > <f:view> > > <h:messages styleClass="errors" showSummary="true" showDetail="true"/> > > <h:form> > > <x:panelTabbedPane binding="#{visit.positionenTabPane}"> > > <x:panelTab id="tab1" label="#{bundle.kopfdaten}"> > > <h:panelGrid columns="3" border="0" cellpadding="5" cellspacing="3"> > > <h:outputLabel for="Positionsnummer"> > > <h:outputText value="#{bundle.posNr}" /> > > </h:outputLabel> > > <h:inputText id="Positionsnummer" size="10" maxlength="10" > > required="true" value="#{visit.currentPosition.posNr}"> > > <f:validateLength minimum="1" maximum="10" /> > > </h:inputText> > > <h:message for="Positionsnummer" styleClass="errors" /> > > </h:panelGrid> > > </x:panelTab> > > <x:panelTab id="tab2" label="#{bundle.operation}"> > > <h:panelGrid columns="3" border="0" cellpadding="5" cellspacing="3"> > > <h:outputLabel for="op_Bewertungsfaktor"> > > <h:outputText value="#{bundle.bewertungsfaktor}" /> > > </h:outputLabel> > > <h:inputText id="op_Bewertungsfaktor" size="10" maxlength="10" > > required="true" > > value="#{visit.currentPosition.op.bewertungsfaktor}"> > > <f:validateDoubleRange minimum="0" maximum="1" /> > > </h:inputText> > > <h:message for="op_Bewertungsfaktor" styleClass="errors" /> > > </h:panelGrid> > > </x:panelTab> > > </x:panelTabbedPane> > > > > <h:commandButton value="#{bundle.ok}" > > action="#{visit.currentPosition.ok}" /> > > > > </h:form> > > </f:view> > > > > Regards, > > Philipp > > >

