Note that there are some explanatory texts on larger screens.

plurals
  1. POhow can i find component in another form or outer of form but in same tab
    primarykey
    data
    text
    <p>i find if i set a form with a datatable with row editor mode,and there is input validator. much more,a grid with input component with validator.so i can not find grid in form. if i set two form ,i can not find each other component in each form. i find component with :formid:compentid. i just want to edit foodcategoryform with delete button and add category with update foodcategoryform .but it can not...primefaces.thank u.</p> <pre><code> &lt;p:tab title="食品分类" id="foodtab"&gt; &lt;h:form id="foodcategoryform"&gt; &lt;f:facet name="header"&gt; &lt;/f:facet&gt; &lt;p:dataTable id="categorytable" var="foodcategories" value="#{foodManagerController.foodCategories}" editable="true" paginator="true" paginatorPosition="bottom" paginatorTemplate="{CurrentPageReport} {FirstPageLink} {PreviousPageLink} {PageLinks} {NextPageLink} {LastPageLink} {RowsPerPageDropdown}" rowsPerPageTemplate="5,10,15" rows="5" paginatorAlwaysVisible="false" emptyMessage="当前系统没有分类数据" editMode="row" resizableColumns="true" &gt; &lt;p:ajax event="rowEdit" update="@this" listener="#{foodManagerController.updateFoodCategory}" /&gt; &lt;p:column headerText="名称" style="width:25%"&gt; &lt;p:growl id="categorymsg"&gt;&lt;/p:growl&gt; &lt;p:cellEditor&gt; &lt;f:facet name="output"&gt;&lt;h:outputText value="#{foodcategories.typeName}" /&gt;&lt;/f:facet&gt; &lt;f:facet name="input"&gt; &lt;p:inputText value="#{foodcategories.typeName}" &gt; &lt;f:validator validatorId="foodCateIsExistValidator" /&gt; &lt;f:attribute name="objectid" value="#{foodcategories.id}"&gt;&lt;/f:attribute&gt; &lt;p:ajax update="categorymsg" event="keyup" /&gt; &lt;/p:inputText&gt; &lt;/f:facet&gt; &lt;/p:cellEditor&gt; &lt;/p:column&gt; &lt;p:column headerText="描述" style="width:25%"&gt; &lt;p:cellEditor&gt; &lt;f:facet name="output"&gt;&lt;h:outputText value="#{foodcategories.typeDesc}" /&gt;&lt;/f:facet&gt; &lt;f:facet name="input"&gt;&lt;p:inputText value="#{foodcategories.typeDesc}" &gt;&lt;f:validateRequired/&gt;&lt;/p:inputText&gt;&lt;/f:facet&gt; &lt;/p:cellEditor&gt; &lt;/p:column&gt; &lt;p:column style="width:6%" headerText="修改"&gt; &lt;p:rowEditor /&gt; &lt;/p:column&gt; &lt;p:column style="width:6%" headerText="删除"&gt; &lt;f:facet name="header"&gt; &lt;h:outputText value="删除" /&gt; &lt;/f:facet&gt; &lt;p:commandButton id="deletebutton" update="categorytable" icon="ui-icon-close" title="删除" actionListener="#{foodManagerController.deletedFoodCatery(foodcategories)}" ajax="true"&gt; &lt;/p:commandButton&gt; &lt;/p:column&gt; &lt;/p:dataTable&gt; &lt;p:panel header="新加种类" toggleable="true" toggleSpeed="500" id="addcategorypanel" &gt; &lt;p:growl id="addcategorymsg" showDetail="true" life="3000" autoUpdate="true"/&gt; &lt;p:outputLabel for="typename" value="种类名称" &gt; &lt;/p:outputLabel&gt; &lt;p:inputText id="typename" value="#{foodManagerController.foodCateName}" &gt; &lt;f:validateRequired/&gt; &lt;f:validator validatorId="foodCateIsExistValidator" /&gt; &lt;p:ajax update="addcategorymsg" event="keyup"/&gt; &lt;/p:inputText&gt; &lt;p:outputLabel for="typedesc" value="种类描述"&gt;&lt;/p:outputLabel&gt; &lt;p:inputText id="typedesc" required="true" requiredMessage="请添加描述" value="#{foodManagerController.foodCateDesc}"&gt; &lt;f:validateRequired/&gt; &lt;p:ajax update="addcategorymsg" event="keyup" /&gt; &lt;/p:inputText&gt; &lt;p:commandButton id="addacate" update="addcategorymsg,categorytable" value="添加" actionListener="#{foodManagerController.addFoodCatery}" ajax="true"/&gt; &lt;/p:panel&gt; &lt;/h:form&gt; &lt;/p:tab&gt; </code></pre>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload