提交父表格但儿童表格未提交

时间:2012-11-24 13:39:52

标签: jsf primefaces

我有一个父表单,而且这个表单在我的五个标签上还包含5个表单。问题是,当我提交我的父表单时,父表单上的数据正在提交,但所有子表单都不在服务器上。正如我认为通过提交父表单所有子表单都被忽略。如果我是对的,请为此问题提出解决方案。我非常感谢你们所有人。我正在使用jsf2.0 primefaces 3.4


将父表单和子表单合并为一个表单后,我的页面出现了一些问题。我无法更新<h:textarea>行选择event.suggest我错误的更新事件我的代码在下面

<h:form id="mainForm">
    <h:panelGrid>
    <p:accordionPanel activeIndex="#{salesLetterProBean.activeIndex}">
        <p:tab title="Product Introduction" id="productinfooTab">
            <p:panel header="Please Fill In The Details" style="padding:5px;"
                id="productInfoPanel">
                <h:panelGrid  cellpadding="1" cellspacing="0" columns="1"
                    columnClasses="a,b,c,d,e" rowClasses="plainRow,shadedRow">
                    <h:outputLabel value="Introductory HeadLine:" class="field-title"
                        id="proInfoPanelGrid"/>
                    <p:inputTextarea value="#{salesLetterProBean.productIntroductoryLineRow.description}"
                        id="proIntroductorySentence"
                        style="width:1060px;height:400px;" effectDuration="400" />
                </h:panelGrid>
                <p:dataTable var="productIntroSentenceList" first="1"
                    value="#{salesLetterProBean.productIntroductorySentenceList}"
                    paginator="true" rows="5" rowsPerPageTemplate="5,10,15,20,25"
                    rowIndexVar="rowIndex" rowKey="#{productIntroSentenceList.id}"
                    selection="#{salesLetterProBean.productIntroductoryLineRow}"
                    selectionMode="single" update="proIntroductorySentence">
                    <p:ajax event="rowSelect" listener="#{salesLetterProBean.onRowSelect}" />
                    <p:column headerText="#">
                        <p:cellEditor>
                            <f:facet name="output">
                                <h:outputText value="#{rowIndex}" />
                            </f:facet>
                            <f:facet name="input">
                                <p:inputText value="#{rowIndex}" />
                            </f:facet>
                        </p:cellEditor>
                    </p:column>
                    <p:column headerText="Description">
                        <p:cellEditor>
                            <f:facet name="output">
                                <h:outputText value="#{productIntroSentenceList.description}" />
                            </f:facet>
                            <f:facet name="input">
                                <p:inputText value="#{productIntroSentenceList.description}" />
                            </f:facet>
                        </p:cellEditor>
                    </p:column>
                    <p:column headerText="Select">
                        <p:commandLink process="@none">
                            <!--  -->
                            <span title="Select" class="ui-icon ui-icon-check"/>
                        </p:commandLink>        
                    </p:column>
                </p:dataTable>
                <h:panelGrid cellpadding="1" cellspacing="0" columns="1"
                    columnClasses="a,b,c,d,e" rowClasses="plainRow,shadedRow">
                    <h:outputLabel value="Feature List:" class="field-title" />
                    <p:inputTextarea style="width:1060px;height:400px;"
                        effectDuration="400" id="featureList"
                        value="#{salesLetterProBean.featureList}"/>
                    <h:outputLabel value="How Your Product Solve The Problems :"
                        class="field-title" />
                    <p:inputTextarea style="width:1060px;height:400px;"
                        effectDuration="400" id="prbSolutions"
                        value="#{salesLetterProBean.problemSolutions}" />
                </h:panelGrid>
                <h:commandButton value="Previous"
                    actionListener="#{applicantManagedBean.changeActiveIndex}"
                    immediate="true" class="defaultButton" />
                <h:commandButton value="   Next   "
                    actionListener="#{applicantManagedBean.changeActiveIndex}"
                    immediate="true" class="defaultButton" />
            </p:panel>
        </p:tab>
    </p:accordionPanel> 
    </h:panelGrid>
</h:form>

问候。

1 个答案:

答案 0 :(得分:0)

不允许嵌套表单,但您可以将多个表单作为堆栈。