Author: jleroux
Date: Sat Apr 2 13:09:40 2011 New Revision: 1088017 URL: http://svn.apache.org/viewvc?rev=1088017&view=rev Log: A patch from Andreas König "EntityLabel support for Product Category Link Types needed." https://issues.apache.org/jira/browse/OFBIZ-4236 applications/product/data/ProductTypeData.xml defines an EnumerationType with enumTypeId="PCAT_LINK_TYPE". The relevant elements next to this enumTypeId are used in the module "catalog / category / links" (see screenshot after applying the given patch). Up to now we use the description given by the XML-Seeds above "hard-wired" in CategoryForms.xml, but it would be nice to have... * a way to add i18n support for the Product Category Link Types by using the ProductEntityLabels.xml and * support for a dynamic generation of the drop down list. Modified: ofbiz/trunk/applications/product/config/ProductEntityLabels.xml ofbiz/trunk/applications/product/widget/catalog/CategoryForms.xml ofbiz/trunk/applications/product/widget/catalog/CategoryScreens.xml Modified: ofbiz/trunk/applications/product/config/ProductEntityLabels.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/product/config/ProductEntityLabels.xml?rev=1088017&r1=1088016&r2=1088017&view=diff ============================================================================== --- ofbiz/trunk/applications/product/config/ProductEntityLabels.xml (original) +++ ofbiz/trunk/applications/product/config/ProductEntityLabels.xml Sat Apr 2 13:09:40 2011 @@ -3016,6 +3016,21 @@ <value xml:lang="zh">被ç</value> <value xml:lang="zh_TW">被ç</value> </property> + <property key="ProductCategoryLinkType.description.PCLT_SEARCH_PARAM"> + <value xml:lang="de">Suchparameter</value> + <value xml:lang="en">Search Parameters</value> + <value xml:lang="fr">Paramètres de recherche</value> + </property> + <property key="ProductCategoryLinkType.description.PCLT_ABS_URL"> + <value xml:lang="de">Absolute URL</value> + <value xml:lang="en">Absolute URL</value> + <value xml:lang="fr">URL absolue</value> + </property> + <property key="ProductCategoryLinkType.description.PCLT_CAT_ID"> + <value xml:lang="de">Kategorie ID</value> + <value xml:lang="en">Category ID</value> + <value xml:lang="fr">Ref. de catégorie</value> + </property> <!-- Field Descriptions --> <!-- ProdCatalog --> Modified: ofbiz/trunk/applications/product/widget/catalog/CategoryForms.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/product/widget/catalog/CategoryForms.xml?rev=1088017&r1=1088016&r2=1088017&view=diff ============================================================================== --- ofbiz/trunk/applications/product/widget/catalog/CategoryForms.xml (original) +++ ofbiz/trunk/applications/product/widget/catalog/CategoryForms.xml Sat Apr 2 13:09:40 2011 @@ -192,12 +192,8 @@ under the License. <field name="imageUrl" tooltip="${uiLabelMap.ProductImageUrlTooltip}"><text size="60" maxlength="255"/></field> <field name="linkTypeEnumId" title="${uiLabelMap.ProductLinkTypeEnumId}"> <drop-down allow-empty = "false"> - <entity-options description="${description}" entity-name="Enumeration" key-field-name="enumId"> - <entity-constraint name="enumId" operator="equals" value="PCLT_SEARCH_PARAM"/> - <entity-order-by field-name="description"/> - </entity-options> - <entity-options description="${description}" entity-name="Enumeration" key-field-name="enumId"> - <entity-constraint name="enumId" operator="equals" value="PCLT_ABS_URL"/> + <entity-options description="${groovy: uiLabelMap.get("ProductCategoryLinkType.description."+enumId)}" entity-name="Enumeration" key-field-name="enumId"> + <entity-constraint name="enumTypeId" operator="equals" value="PCAT_LINK_TYPE"/> <entity-order-by field-name="description"/> </entity-options> </drop-down> Modified: ofbiz/trunk/applications/product/widget/catalog/CategoryScreens.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/product/widget/catalog/CategoryScreens.xml?rev=1088017&r1=1088016&r2=1088017&view=diff ============================================================================== --- ofbiz/trunk/applications/product/widget/catalog/CategoryScreens.xml (original) +++ ofbiz/trunk/applications/product/widget/catalog/CategoryScreens.xml Sat Apr 2 13:09:40 2011 @@ -483,6 +483,8 @@ under the License. <screen name="EditProductCategoryLinks"> <section> <actions> + <property-map resource="ProductEntityLabels" map-name="uiLabelMap" global="true"/> + <set field="titleProperty" value="PageTitleEditProductCategoryLink"/> <set field="headerItem" value="categories"/> <set field="tabButtonItem" value="EditProductCategoryLinks"/> |
Free forum by Nabble | Edit this page |