Author: buscob
Date: Sat Nov 6 14:35:17 2010 New Revision: 1032077 URL: http://svn.apache.org/viewvc?rev=1032077&view=rev Log: Added simple, standard Find Product screen in Catalog application. Modified: ofbiz/trunk/applications/product/config/ProductUiLabels.xml ofbiz/trunk/applications/product/webapp/catalog/WEB-INF/controller.xml ofbiz/trunk/applications/product/widget/catalog/CatalogMenus.xml ofbiz/trunk/applications/product/widget/catalog/CommonScreens.xml ofbiz/trunk/applications/product/widget/catalog/ProductForms.xml ofbiz/trunk/applications/product/widget/catalog/ProductScreens.xml Modified: ofbiz/trunk/applications/product/config/ProductUiLabels.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/product/config/ProductUiLabels.xml?rev=1032077&r1=1032076&r2=1032077&view=diff ============================================================================== --- ofbiz/trunk/applications/product/config/ProductUiLabels.xml (original) +++ ofbiz/trunk/applications/product/config/ProductUiLabels.xml Sat Nov 6 14:35:17 2010 @@ -5946,6 +5946,10 @@ <value xml:lang="th">Find Inventory Item Labels</value> <value xml:lang="zh">æ¥æ¾åºåæç»æ ç¾</value> </property> + <property key="PageTitleFindProduct"> + <value xml:lang="en">Find Product</value> + <value xml:lang="it">Ricerca prodotti</value> + </property> <property key="PageTitleFindProductCatalog"> <value xml:lang="de">Produktkatalog suchen</value> <value xml:lang="en">Find Product Catalog</value> Modified: ofbiz/trunk/applications/product/webapp/catalog/WEB-INF/controller.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/product/webapp/catalog/WEB-INF/controller.xml?rev=1032077&r1=1032076&r2=1032077&view=diff ============================================================================== --- ofbiz/trunk/applications/product/webapp/catalog/WEB-INF/controller.xml (original) +++ ofbiz/trunk/applications/product/webapp/catalog/WEB-INF/controller.xml Sat Nov 6 14:35:17 2010 @@ -431,7 +431,11 @@ under the License. </request-map> <!-- ================ Product Requests ================= --> - <request-map uri="EditProduct"> + <request-map uri="FindProduct"> + <security https="true" auth="true"/> + <response name="success" type="view" value="FindProduct"/> + </request-map> + <request-map uri="EditProduct"> <security https="true" auth="true"/> <response name="success" type="view" value="EditProduct"/> </request-map> @@ -2754,6 +2758,7 @@ under the License. <view-map name="createProductInCategoryStart" type="screen" page="component://product/widget/catalog/CategoryScreens.xml#createProductInCategoryStart"/> <view-map name="CreateProductInCategoryCheckExisting" type="screen" page="component://product/widget/catalog/CategoryScreens.xml#CreateProductInCategoryCheckExisting"/> + <view-map name="FindProduct" type="screen" page="component://product/widget/catalog/ProductScreens.xml#FindProduct"/> <view-map name="EditProduct" type="screen" page="component://product/widget/catalog/ProductScreens.xml#EditProduct"/> <view-map name="EditProductPrices" type="screen" page="component://product/widget/catalog/ProductScreens.xml#EditProductPrices"/> <view-map name="EditProductAssetUsage" type="screen" page="component://product/widget/catalog/ProductScreens.xml#EditProductAssetUsage"/> Modified: ofbiz/trunk/applications/product/widget/catalog/CatalogMenus.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/product/widget/catalog/CatalogMenus.xml?rev=1032077&r1=1032076&r2=1032077&view=diff ============================================================================== --- ofbiz/trunk/applications/product/widget/catalog/CatalogMenus.xml (original) +++ ofbiz/trunk/applications/product/widget/catalog/CatalogMenus.xml Sat Nov 6 14:35:17 2010 @@ -19,6 +19,7 @@ under the License. --> <menus xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://ofbiz.apache.org/dtds/widget-menu.xsd"> <menu name="CatalogAppBar" title="${uiLabelMap.ProductCatalogManager}" extends="CommonAppBarMenu" extends-resource="component://common/widget/CommonMenus.xml"> + <menu-item name="products" title="${uiLabelMap.ProductProducts}"><link target="FindProduct"/></menu-item> <menu-item name="featurecats" title="${uiLabelMap.ProductFeatureCats}"><link target="EditFeatureCategories"/></menu-item> <menu-item name="promos" title="${uiLabelMap.ProductPromos}"><link target="FindProductPromo"/></menu-item> <menu-item name="pricerules" title="${uiLabelMap.ProductPriceRules}"><link target="FindProductPriceRules"/></menu-item> Modified: ofbiz/trunk/applications/product/widget/catalog/CommonScreens.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/product/widget/catalog/CommonScreens.xml?rev=1032077&r1=1032076&r2=1032077&view=diff ============================================================================== --- ofbiz/trunk/applications/product/widget/catalog/CommonScreens.xml (original) +++ ofbiz/trunk/applications/product/widget/catalog/CommonScreens.xml Sat Nov 6 14:35:17 2010 @@ -51,6 +51,7 @@ under the License. <screen name="CommonProductDecorator"> <section> <actions> + <set field="headerItem" value="products"/> <property-map resource="PartyUiLabels" map-name="uiLabelMap" global="true"/> <property-map resource="OrderUiLabels" map-name="uiLabelMap" global="true"/> <set field="productId" from-field="parameters.productId"/> @@ -117,9 +118,9 @@ under the License. </or> </condition> <widgets> - <decorator-section-include name="body"/> - </widgets> - <fail-widgets> + <decorator-section-include name="body"/> + </widgets> + <fail-widgets> <label style="h3">${uiLabelMap.ProductNoExistingProductsFound}</label> </fail-widgets> </section> Modified: ofbiz/trunk/applications/product/widget/catalog/ProductForms.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/product/widget/catalog/ProductForms.xml?rev=1032077&r1=1032076&r2=1032077&view=diff ============================================================================== --- ofbiz/trunk/applications/product/widget/catalog/ProductForms.xml (original) +++ ofbiz/trunk/applications/product/widget/catalog/ProductForms.xml Sat Nov 6 14:35:17 2010 @@ -20,12 +20,41 @@ under the License. <forms xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://ofbiz.apache.org/dtds/widget-form.xsd"> - <!-- UNUSED FORM - <form name="EditProductSimpleTest" type="single" target="updateProduct" title="" + <form name="FindProduct" type="single" target="FindProduct" title="" default-map-name="product" header-row-style="header-row" default-table-style="basic-table"> - <auto-fields-service service-name="updateProduct" map-name="product"/> + <field name="noConditionFind"><hidden value="Y"/><!-- if this isn't there then with all fields empty no query will be done --></field> + <field name="productId" title="${uiLabelMap.ProductProductId}"><text-find/></field> + <field name="internalName" title="${uiLabelMap.ProductInternalName}"><text-find/></field> + <field name="submitButton" title="${uiLabelMap.CommonFind}" widget-style="smallSubmit"> + <submit button-type="button"/> + </field> </form> - --> + + <form name="ListProducts" list-name="listIt" target="" title="" type="list" paginate-target="FindProduct" + odd-row-style="alternate-row" default-table-style="basic-table hover-bar" header-row-style="header-row-2"> + <actions> + <set field="entityName" value="Product"/> + <service service-name="performFind" result-map="result" result-map-list="listIt"> + <field-map field-name="inputFields" from-field="requestParameters"/> + <field-map field-name="entityName" from-field="entityName"/> + <field-map field-name="orderBy" from-field="parameters.sortField"/> + <field-map field-name="viewIndex" from-field="viewIndex"/> + <field-map field-name="viewSize" from-field="viewSize"/> + </service> + </actions> + <field name="productId" sort-field="true"> + <hyperlink also-hidden="false" description="${productId}" target="EditProduct"> + <parameter param-name="productId"/> + </hyperlink> + </field> + + <field name="internalName" sort-field="true"><display/></field> + <field name="brandName" sort-field="true"><display/></field> + <field name="productName" sort-field="true"><display/></field> + <field name="description" sort-field="true"><display/></field> + </form> + + <form name="EditProduct" type="single" target="updateProduct" title="" default-map-name="product" header-row-style="header-row" default-table-style="basic-table"> Modified: ofbiz/trunk/applications/product/widget/catalog/ProductScreens.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/product/widget/catalog/ProductScreens.xml?rev=1032077&r1=1032076&r2=1032077&view=diff ============================================================================== --- ofbiz/trunk/applications/product/widget/catalog/ProductScreens.xml (original) +++ ofbiz/trunk/applications/product/widget/catalog/ProductScreens.xml Sat Nov 6 14:35:17 2010 @@ -21,6 +21,42 @@ under the License. <screens xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://ofbiz.apache.org/dtds/widget-screen.xsd"> + <screen name="FindProduct"> + <section> + <actions> + <set field="titleProperty" value="PageTitleFindProduct"/> + </actions> + <widgets> + <decorator-screen name="CommonProductDecorator" location="${parameters.mainDecoratorLocation}"> + <decorator-section name="body"> + <section> + <condition> + <if-service-permission service-name="acctgAgreementPermissionCheck" main-action="VIEW"/> + </condition> + <widgets> + <decorator-screen name="FindScreenDecorator" location="component://common/widget/CommonScreens.xml"> + <decorator-section name="menu-bar"> + <container style="button-bar"> + <link target="EditProduct" text="${uiLabelMap.ProductNewProduct}" style="buttontext create"/> + </container> + </decorator-section> + <decorator-section name="search-options"> + <include-form name="FindProduct" location="component://product/widget/catalog/ProductForms.xml"/> + </decorator-section> + <decorator-section name="search-results"> + <include-form name="ListProducts" location="component://product/widget/catalog/ProductForms.xml"/> + </decorator-section> + </decorator-screen> + </widgets> + <fail-widgets> + <label style="h3">${uiLabelMap.AccountingViewPermissionError}</label> + </fail-widgets> + </section> + </decorator-section> + </decorator-screen> + </widgets> + </section> + </screen> <screen name="EditProduct"> <section> <actions> |
Free forum by Nabble | Edit this page |