|
Modified: ofbiz/branches/20120329_portletWidget/applications/order/src/org/ofbiz/order/shoppinglist/ShoppingListEvents.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/20120329_portletWidget/applications/order/src/org/ofbiz/order/shoppinglist/ShoppingListEvents.java?rev=1401975&r1=1401974&r2=1401975&view=diff ============================================================================== --- ofbiz/branches/20120329_portletWidget/applications/order/src/org/ofbiz/order/shoppinglist/ShoppingListEvents.java (original) +++ ofbiz/branches/20120329_portletWidget/applications/order/src/org/ofbiz/order/shoppinglist/ShoppingListEvents.java Thu Oct 25 05:04:09 2012 @@ -57,6 +57,7 @@ import org.ofbiz.service.GenericServiceE import org.ofbiz.service.LocalDispatcher; import org.ofbiz.service.ModelService; import org.ofbiz.service.ServiceUtil; +import org.ofbiz.webapp.website.WebSiteWorker; /** * Shopping cart events. @@ -459,7 +460,7 @@ public class ShoppingListEvents { // safety check for missing required parameter. if (cart.getWebSiteId() == null) { - cart.setWebSiteId(CatalogWorker.getWebSiteId(request)); + cart.setWebSiteId(WebSiteWorker.getWebSiteId(request)); } // locate the user's identity Modified: ofbiz/branches/20120329_portletWidget/applications/order/webapp/ordermgr/WEB-INF/actions/entry/CheckoutReview.groovy URL: http://svn.apache.org/viewvc/ofbiz/branches/20120329_portletWidget/applications/order/webapp/ordermgr/WEB-INF/actions/entry/CheckoutReview.groovy?rev=1401975&r1=1401974&r2=1401975&view=diff ============================================================================== --- ofbiz/branches/20120329_portletWidget/applications/order/webapp/ordermgr/WEB-INF/actions/entry/CheckoutReview.groovy (original) +++ ofbiz/branches/20120329_portletWidget/applications/order/webapp/ordermgr/WEB-INF/actions/entry/CheckoutReview.groovy Thu Oct 25 05:04:09 2012 @@ -28,6 +28,7 @@ import org.ofbiz.product.catalog.*; import org.ofbiz.order.shoppingcart.*; import org.ofbiz.product.store.*; import org.ofbiz.party.party.PartyWorker; +import org.ofbiz.webapp.website.WebSiteWorker cart = ShoppingCartEvents.getCartObject(request); context.cart = cart; @@ -90,7 +91,7 @@ if (paymentMethodTypeIds) { context.paymentMethodType = paymentMethodType; } -webSiteId = CatalogWorker.getWebSiteId(request); +webSiteId = WebSiteWorker.getWebSiteId(request); productStoreId = ProductStoreWorker.getProductStoreId(request); productStore = ProductStoreWorker.getProductStore(productStoreId, delegator); if (productStore) { Modified: ofbiz/branches/20120329_portletWidget/applications/order/webapp/ordermgr/WEB-INF/actions/entry/catalog/InlineProductDetail.groovy URL: http://svn.apache.org/viewvc/ofbiz/branches/20120329_portletWidget/applications/order/webapp/ordermgr/WEB-INF/actions/entry/catalog/InlineProductDetail.groovy?rev=1401975&r1=1401974&r2=1401975&view=diff ============================================================================== --- ofbiz/branches/20120329_portletWidget/applications/order/webapp/ordermgr/WEB-INF/actions/entry/catalog/InlineProductDetail.groovy (original) +++ ofbiz/branches/20120329_portletWidget/applications/order/webapp/ordermgr/WEB-INF/actions/entry/catalog/InlineProductDetail.groovy Thu Oct 25 05:04:09 2012 @@ -27,6 +27,7 @@ import org.ofbiz.entity.condition.*; import org.ofbiz.entity.util.*; import org.ofbiz.webapp.taglib.*; import org.ofbiz.webapp.stats.VisitHandler; +import org.ofbiz.webapp.website.WebSiteWorker import org.ofbiz.order.shoppingcart.ShoppingCartEvents; import org.ofbiz.product.catalog.*; import org.ofbiz.product.category.*; @@ -122,7 +123,7 @@ if (inlineProduct) { // get the product price - webSiteId = CatalogWorker.getWebSiteId(request); + webSiteId = WebSiteWorker.getWebSiteId(request); autoUserLogin = request.getSession().getAttribute("autoUserLogin"); if (cart.isSalesOrder()) { // sales order: run the "calculateProductPrice" service Modified: ofbiz/branches/20120329_portletWidget/applications/order/webapp/ordermgr/WEB-INF/actions/entry/catalog/ProductDetail.groovy URL: http://svn.apache.org/viewvc/ofbiz/branches/20120329_portletWidget/applications/order/webapp/ordermgr/WEB-INF/actions/entry/catalog/ProductDetail.groovy?rev=1401975&r1=1401974&r2=1401975&view=diff ============================================================================== --- ofbiz/branches/20120329_portletWidget/applications/order/webapp/ordermgr/WEB-INF/actions/entry/catalog/ProductDetail.groovy (original) +++ ofbiz/branches/20120329_portletWidget/applications/order/webapp/ordermgr/WEB-INF/actions/entry/catalog/ProductDetail.groovy Thu Oct 25 05:04:09 2012 @@ -37,6 +37,7 @@ import org.ofbiz.product.product.Product import org.ofbiz.product.catalog.*; import org.ofbiz.product.store.*; import org.ofbiz.webapp.stats.VisitHandler; +import org.ofbiz.webapp.website.WebSiteWorker import org.ofbiz.order.shoppingcart.ShoppingCartEvents; import org.ofbiz.order.shoppingcart.ShoppingCart; @@ -165,7 +166,7 @@ if (product) { // get the product price catalogId = CatalogWorker.getCurrentCatalogId(request); currentCatalogId = catalogId; - webSiteId = CatalogWorker.getWebSiteId(request); + webSiteId = WebSiteWorker.getWebSiteId(request); autoUserLogin = request.getSession().getAttribute("autoUserLogin"); if (cart.isSalesOrder()) { // sales order: run the "calculateProductPrice" service Modified: ofbiz/branches/20120329_portletWidget/applications/order/webapp/ordermgr/WEB-INF/actions/entry/catalog/ProductSummary.groovy URL: http://svn.apache.org/viewvc/ofbiz/branches/20120329_portletWidget/applications/order/webapp/ordermgr/WEB-INF/actions/entry/catalog/ProductSummary.groovy?rev=1401975&r1=1401974&r2=1401975&view=diff ============================================================================== --- ofbiz/branches/20120329_portletWidget/applications/order/webapp/ordermgr/WEB-INF/actions/entry/catalog/ProductSummary.groovy (original) +++ ofbiz/branches/20120329_portletWidget/applications/order/webapp/ordermgr/WEB-INF/actions/entry/catalog/ProductSummary.groovy Thu Oct 25 05:04:09 2012 @@ -32,6 +32,7 @@ import org.ofbiz.product.catalog.*; import org.ofbiz.product.store.*; import org.ofbiz.order.shoppingcart.*; import org.ofbiz.product.product.ProductWorker; +import org.ofbiz.webapp.website.WebSiteWorker import java.text.NumberFormat; //either optProduct, optProductId or productId must be specified @@ -39,7 +40,7 @@ product = request.getAttribute("optProdu optProductId = request.getAttribute("optProductId"); productId = product?.productId ?: optProductId ?: request.getAttribute("productId"); -webSiteId = CatalogWorker.getWebSiteId(request); +webSiteId = WebSiteWorker.getWebSiteId(request); catalogId = CatalogWorker.getCurrentCatalogId(request); cart = ShoppingCartEvents.getCartObject(request); productStore = null; Modified: ofbiz/branches/20120329_portletWidget/applications/order/webapp/ordermgr/entry/optionsettings.ftl URL: http://svn.apache.org/viewvc/ofbiz/branches/20120329_portletWidget/applications/order/webapp/ordermgr/entry/optionsettings.ftl?rev=1401975&r1=1401974&r2=1401975&view=diff ============================================================================== --- ofbiz/branches/20120329_portletWidget/applications/order/webapp/ordermgr/entry/optionsettings.ftl (original) +++ ofbiz/branches/20120329_portletWidget/applications/order/webapp/ordermgr/entry/optionsettings.ftl Thu Oct 25 05:04:09 2012 @@ -18,6 +18,7 @@ under the License. --> <#if security.hasEntityPermission("ORDERMGR", "_CREATE", session) || security.hasEntityPermission("ORDERMGR", "_PURCHASE_CREATE", session)> +<form method="post" action="<@ofbizUrl>finalizeOrder</@ofbizUrl>" name="checkoutsetupform"> <table border="0" width='100%' cellspacing='0' cellpadding='0' class='boxoutside'> <tr> <td width='100%'> @@ -36,10 +37,10 @@ under the License. </tr> <tr> <td colspan="2"> - <textarea cols="30" rows="3" name="internal_order_notes"></textarea> + <textarea cols="30" rows="3" name="internal_order_notes"><#if (cart.getInternalOrderNotes().size()>0)>${(cart.getInternalOrderNotes()[0])?if_exists}</#if></textarea> </td> <td colspan="2"> - <textarea cols="30" rows="3" name="shippingNotes"></textarea> + <textarea cols="30" rows="3" name="shippingNotes"><#if (cart.getOrderNotes().size()>0)>${(cart.getOrderNotes()[0])?if_exists}</#if></textarea> </td> </tr> </table> @@ -47,7 +48,6 @@ under the License. </tr> <tr> <td> - <form method="post" action="<@ofbizUrl>finalizeOrder</@ofbizUrl>" name="checkoutsetupform"> <input type="hidden" name="finalizeMode" value="options"/> <#list 1..cart.getShipGroupSize() as currIndex> <#assign shipGroupIndex = currIndex - 1> @@ -149,7 +149,7 @@ under the License. <tr> <td colspan="2"> <div> - <@htmlTemplate.renderDateTimeField name="sgi${shipGroupIndex?default('0')}_shipBeforeDate" event="" action="" value="" className="" alert="" title="Format: yyyy-MM-dd HH:mm:ss.SSS" size="25" maxlength="30" id="sgi${shipGroupIndex?default('0')}_shipBeforeDate" dateType="date" shortDateInput=false timeDropdownParamName="" defaultDateTimeString="" localizedIconTitle="" timeDropdown="" timeHourName="" classString="" hour1="" hour2="" timeMinutesName="" minutes="" isTwelveHour="" ampmName="" amSelected="" pmSelected="" compositeType="" formName=""/> + <@htmlTemplate.renderDateTimeField name="sgi${shipGroupIndex?default('0')}_shipBeforeDate" event="" action="" value="${(cart.getShipBeforeDate())?if_exists}" className="" alert="" title="Format: yyyy-MM-dd HH:mm:ss.SSS" size="25" maxlength="30" id="sgi${shipGroupIndex?default('0')}_shipBeforeDate" dateType="date" shortDateInput=false timeDropdownParamName="" defaultDateTimeString="" localizedIconTitle="" timeDropdown="" timeHourName="" classString="" hour1="" hour2="" timeMinutesName="" minutes="" isTwelveHour="" ampmName="" amSelected="" pmSelected="" compositeType="" formName=""/> </div> </td> </tr> @@ -161,7 +161,7 @@ under the License. <tr> <td colspan="2"> <div> - <@htmlTemplate.renderDateTimeField name="sgi${shipGroupIndex?default('0')}_shipAfterDate" event="" action="" value="" className="" alert="" title="Format: yyyy-MM-dd HH:mm:ss.SSS" size="25" maxlength="30" id="sgi${shipGroupIndex?default('0')}_shipAfterDate" dateType="date" shortDateInput=false timeDropdownParamName="" defaultDateTimeString="" localizedIconTitle="" timeDropdown="" timeHourName="" classString="" hour1="" hour2="" timeMinutesName="" minutes="" isTwelveHour="" ampmName="" amSelected="" pmSelected="" compositeType="" formName=""/> + <@htmlTemplate.renderDateTimeField name="sgi${shipGroupIndex?default('0')}_shipAfterDate" event="" action="" value="${(cart.getShipAfterDate())?if_exists}" className="" alert="" title="Format: yyyy-MM-dd HH:mm:ss.SSS" size="25" maxlength="30" id="sgi${shipGroupIndex?default('0')}_shipAfterDate" dateType="date" shortDateInput=false timeDropdownParamName="" defaultDateTimeString="" localizedIconTitle="" timeDropdown="" timeHourName="" classString="" hour1="" hour2="" timeMinutesName="" minutes="" isTwelveHour="" ampmName="" amSelected="" pmSelected="" compositeType="" formName=""/> </div> </td> </tr> @@ -207,14 +207,13 @@ under the License. </tr> </table> </#list> - </form> </td> </tr> </table> </td> </tr> </table> - +</form> <br /> <#else> <h3>${uiLabelMap.OrderViewPermissionError}</h3> Modified: ofbiz/branches/20120329_portletWidget/applications/order/webapp/ordermgr/order/findOrders.ftl URL: http://svn.apache.org/viewvc/ofbiz/branches/20120329_portletWidget/applications/order/webapp/ordermgr/order/findOrders.ftl?rev=1401975&r1=1401974&r2=1401975&view=diff ============================================================================== --- ofbiz/branches/20120329_portletWidget/applications/order/webapp/ordermgr/order/findOrders.ftl (original) +++ ofbiz/branches/20120329_portletWidget/applications/order/webapp/ordermgr/order/findOrders.ftl Thu Oct 25 05:04:09 2012 @@ -532,12 +532,12 @@ document.lookuporder.orderId.focus(); </#list> </#if> </form> - <form name="massOrderChangeForm" method="post" action="javascript:void();"> + <form name="massOrderChangeForm" method="post" action="javascript:void(0);"> <div> </div> <div align="right"> <input type="hidden" name="screenLocation" value="component://order/widget/ordermgr/OrderPrintScreens.xml#OrderPDF"/> <select name="serviceName" onchange="javascript:setServiceName(this);"> - <option value="javascript:void();"> </option> + <option value="javascript:void(0);"> </option> <option value="<@ofbizUrl>massApproveOrders?hideFields=${requestParameters.hideFields?default("N")}${paramList}</@ofbizUrl>">${uiLabelMap.OrderApproveOrder}</option> <option value="<@ofbizUrl>massHoldOrders?hideFields=${requestParameters.hideFields?default("N")}${paramList}</@ofbizUrl>">${uiLabelMap.OrderHold}</option> <option value="<@ofbizUrl>massProcessOrders?hideFields=${requestParameters.hideFields?default("N")}${paramList}</@ofbizUrl>">${uiLabelMap.OrderProcessOrder}</option> @@ -550,7 +550,7 @@ document.lookuporder.orderId.focus(); <option value="<@ofbizUrl>massCreateFileForOrders?hideFields=${requestParameters.hideFields?default('N')}${paramList}</@ofbizUrl>">${uiLabelMap.ContentCreateFile}</option> </select> <select name="printerName"> - <option value="javascript:void();"> </option> + <option value="javascript:void(0);"> </option> <#list printers as printer> <option value="${printer}">${printer}</option> </#list> Modified: ofbiz/branches/20120329_portletWidget/applications/party/webapp/partymgr/WEB-INF/actions/party/EditShoppingList.groovy URL: http://svn.apache.org/viewvc/ofbiz/branches/20120329_portletWidget/applications/party/webapp/partymgr/WEB-INF/actions/party/EditShoppingList.groovy?rev=1401975&r1=1401974&r2=1401975&view=diff ============================================================================== --- ofbiz/branches/20120329_portletWidget/applications/party/webapp/partymgr/WEB-INF/actions/party/EditShoppingList.groovy (original) +++ ofbiz/branches/20120329_portletWidget/applications/party/webapp/partymgr/WEB-INF/actions/party/EditShoppingList.groovy Thu Oct 25 05:04:09 2012 @@ -20,9 +20,10 @@ import org.ofbiz.entity.util.EntityUtil; import org.ofbiz.base.util.UtilHttp; import org.ofbiz.product.catalog.CatalogWorker; +import org.ofbiz.webapp.website.WebSiteWorker prodCatalogId = CatalogWorker.getCurrentCatalogId(request); -webSiteId = CatalogWorker.getWebSiteId(request); +webSiteId = WebSiteWorker.getWebSiteId(request); currencyUomId = parameters.currencyUomId ?: UtilHttp.getCurrencyUom(request); context.currencyUomId = currencyUomId; Modified: ofbiz/branches/20120329_portletWidget/applications/product/config/ProductUiLabels.xml URL: http://svn.apache.org/viewvc/ofbiz/branches/20120329_portletWidget/applications/product/config/ProductUiLabels.xml?rev=1401975&r1=1401974&r2=1401975&view=diff ============================================================================== --- ofbiz/branches/20120329_portletWidget/applications/product/config/ProductUiLabels.xml (original) +++ ofbiz/branches/20120329_portletWidget/applications/product/config/ProductUiLabels.xml Thu Oct 25 05:04:09 2012 @@ -4975,6 +4975,41 @@ <value xml:lang="zh">产ååºéºç»æ è¯</value> <value xml:lang="zh_TW">ç¢åååºç¾¤çµID</value> </property> + <property key="FormFieldTitle_productStoreGroupName"> + <value xml:lang="ar">إس٠</value> + <value xml:lang="de">Name</value> + <value xml:lang="en">Name</value> + <value xml:lang="es">Nombre</value> + <value xml:lang="fr">Nom</value> + <value xml:lang="hi_IN">नाम</value> + <value xml:lang="it">Nome</value> + <value xml:lang="nl">Naam</value> + <value xml:lang="pt">Nome</value> + <value xml:lang="ro">Nume</value> + <value xml:lang="ru">ÐмÑ</value> + <value xml:lang="th">à¸à¸·à¹à¸</value> + <value xml:lang="zh">åç§°</value> + <value xml:lang="zh_CN">åç§°</value> + <value xml:lang="zh_TW">å稱</value> + </property> + <property key="FormFieldTitle_productStoreGroupTypeId"> + <value xml:lang="ar">اÙÙÙØ¹</value> + <value xml:lang="de">Typ</value> + <value xml:lang="en">Type</value> + <value xml:lang="es">Tipo</value> + <value xml:lang="fr">Type</value> + <value xml:lang="hi_IN">पà¥à¤°à¤à¤¾à¤°</value> + <value xml:lang="it">Tipo</value> + <value xml:lang="nl">Soort</value> + <value xml:lang="pt">Tipo</value> + <value xml:lang="ro">Tip</value> + <value xml:lang="ru">Тип</value> + <value xml:lang="th">à¸à¸£à¸°à¹à¸ à¸</value> + <value xml:lang="vi">Chá»§ng loại</value> + <value xml:lang="zh">ç±»å</value> + <value xml:lang="zh_CN">ç±»å</value> + <value xml:lang="zh_TW">é¡å</value> + </property> <property key="FormFieldTitle_productStoreId"> <value xml:lang="ar">تعرÙ٠اÙ٠تجر</value> <value xml:lang="de">Produkt Laden ID</value> @@ -10243,6 +10278,10 @@ <value xml:lang="zh">æ·»å å°å è£ </value> <value xml:lang="zh_TW">æ·»å å°å è£</value> </property> + <property key="ProductAddToProductStoreGroup"> + <value xml:lang="en">Add To Product Store Group</value> + <value xml:lang="fr">Ajout au groupe de centre de profit</value> + </property> <property key="ProductAddToShoppingList"> <value xml:lang="de">Zu Einkaufsliste hinzufügen</value> <value xml:lang="en">Add to shopping list</value> @@ -20211,6 +20250,14 @@ <value xml:lang="zh">ä¸çº§ç» [æ è¯]</value> <value xml:lang="zh_TW">ä¸ç´çµ [ID]</value> </property> + <property key="ProductParentProductStoreGroups"> + <value xml:lang="en">Parent Product Store Groups</value> + <value xml:lang="fr">Groupes de centre de profit parent</value> + </property> + <property key="ProductParentProductStoreGroupList"> + <value xml:lang="en">Parent Product Store Group List</value> + <value xml:lang="fr">Liste des groupes de centre de profit parent</value> + </property> <property key="ProductParentType"> <value xml:lang="de">Ãbergeordneter Produkttyp</value> <value xml:lang="en">Product Parent Type</value> @@ -21564,6 +21611,22 @@ <value xml:lang="zh">产ååºéºç»æ è¯</value> <value xml:lang="zh_TW">ç¢åååºç¾¤çµID</value> </property> + <property key="ProductProductStoreGroupRollup"> + <value xml:lang="en">Product Store Rollup</value> + <value xml:lang="fr">Groupes de centre de profit enfant</value> + </property> + <property key="ProductProductStoreGroups"> + <value xml:lang="en">Product Store Groups</value> + <value xml:lang="fr">Groupes de centre de profit</value> + </property> + <property key="ProductProductStoreGroupMain"> + <value xml:lang="en">Product Store main</value> + <value xml:lang="fr">Accueil groupes</value> + </property> + <property key="ProductProductStoreMember"> + <value xml:lang="en">Product Store Member</value> + <value xml:lang="fr">Centres de profit associés</value> + </property> <property key="ProductProductStoreNotFound"> <value xml:lang="en">No ProductStore found with id ${parameters.productStoreId}, not reserving inventory.</value> <value xml:lang="it">Nessun negozio trovato con id ${parameters.productStoreId}, nessun inventario verrà riservato.</value> Modified: ofbiz/branches/20120329_portletWidget/applications/product/data/ProductDemoData.xml URL: http://svn.apache.org/viewvc/ofbiz/branches/20120329_portletWidget/applications/product/data/ProductDemoData.xml?rev=1401975&r1=1401974&r2=1401975&view=diff ============================================================================== --- ofbiz/branches/20120329_portletWidget/applications/product/data/ProductDemoData.xml (original) +++ ofbiz/branches/20120329_portletWidget/applications/product/data/ProductDemoData.xml Thu Oct 25 05:04:09 2012 @@ -43,4 +43,6 @@ under the License. <UserLoginSecurityGroup userLoginId="imageUpload" groupId="IMAGEUPLOAD" fromDate="2010-01-01 12:00:00.0"/> <PartyRole partyId="admin" roleTypeId="IMAGEAPPROVER"/> + <!-- Product store group management demo --> + <ProductStoreGroupType productStoreGroupTypeId="PSGT_AREA" description="Area cover"/> </entity-engine-xml> Modified: ofbiz/branches/20120329_portletWidget/applications/product/entitydef/entitymodel_view.xml URL: http://svn.apache.org/viewvc/ofbiz/branches/20120329_portletWidget/applications/product/entitydef/entitymodel_view.xml?rev=1401975&r1=1401974&r2=1401975&view=diff ============================================================================== --- ofbiz/branches/20120329_portletWidget/applications/product/entitydef/entitymodel_view.xml (original) +++ ofbiz/branches/20120329_portletWidget/applications/product/entitydef/entitymodel_view.xml Thu Oct 25 05:04:09 2012 @@ -80,4 +80,29 @@ under the License. <key-map field-name="productId"/> </view-link> </view-entity> + + <view-entity entity-name="ProductStoreGroupAndMember" package-name="org.ofbiz.product.store" title="ProductStoreGroup And ProductStore View Entiry"> + <member-entity entity-alias="PSG" entity-name="ProductStoreGroup"/> + <member-entity entity-alias="PSGM" entity-name="ProductStoreGroupMember"/> + <member-entity entity-alias="PS" entity-name="ProductStore"/> + <alias-all entity-alias="PSG"/> + <alias-all entity-alias="PSGM"/> + <alias-all entity-alias="PS"/> + <view-link entity-alias="PSG" rel-entity-alias="PSGM"> + <key-map field-name="productStoreGroupId"/> + </view-link> + <view-link entity-alias="PSGM" rel-entity-alias="PS"> + <key-map field-name="productStoreId"/> + </view-link> + </view-entity> + + <view-entity entity-name="ProductStoreGroupRollupAndChild" package-name="org.ofbiz.product.store" title="ProductStoreGroupRollup And ProductStoreGroup View Entiry"> + <member-entity entity-alias="PSGR" entity-name="ProductStoreGroupRollup"/> + <member-entity entity-alias="PSG" entity-name="ProductStoreGroup"/> + <alias-all entity-alias="PSG"/> + <alias-all entity-alias="PSGR"/> + <view-link entity-alias="PSG" rel-entity-alias="PSGR"> + <key-map field-name="productStoreGroupId"/> + </view-link> + </view-entity> </entitymodel> Modified: ofbiz/branches/20120329_portletWidget/applications/product/script/org/ofbiz/product/store/ProductStoreServices.xml URL: http://svn.apache.org/viewvc/ofbiz/branches/20120329_portletWidget/applications/product/script/org/ofbiz/product/store/ProductStoreServices.xml?rev=1401975&r1=1401974&r2=1401975&view=diff ============================================================================== --- ofbiz/branches/20120329_portletWidget/applications/product/script/org/ofbiz/product/store/ProductStoreServices.xml (original) +++ ofbiz/branches/20120329_portletWidget/applications/product/script/org/ofbiz/product/store/ProductStoreServices.xml Thu Oct 25 05:04:09 2012 @@ -456,6 +456,8 @@ under the License. <simple-method method-name="reserveStoreInventory" short-description="Reserve Store Inventory"> <entity-one entity-name="Product" value-field="product" use-cache="true"/> <entity-one entity-name="ProductStore" value-field="productStore" use-cache="true"/> + <entity-one entity-name="OrderHeader" value-field="orderHeader" use-cache="true"/> + <set field="parameters.priority" from-field="orderHeader.priority"/> <if-empty field="productStore"> <add-error> <fail-property resource="ProductUiLabels" property="ProductProductStoreNotFound"/> @@ -771,5 +773,28 @@ under the License. <remove-value value-field="lookedUpValue"/> </simple-method> + <simple-method method-name="checkProductStoreGroupRollup" short-description="When product store group hierarchy has been operate, synchronize primaryParentGroupId with ProductStoreGroupRollup"> + <entity-one value-field="productStoreGroup" entity-name="ProductStoreGroup"/> + <if-empty field="parameters.primaryParentGroupId"> + <entity-one value-field="productStoreGroupRollup" entity-name="ProductStoreGroupRollup"/> + <if-not-empty field="productStoreGroupRollup"> + <set field="productStoreGroup.primaryParentGroupId"/> + <set-service-fields service-name="updateProductStoreGroup" to-map="productStoreGroupMap" map="productStoreGroup"/> + <call-service service-name="updateProductStoreGroup" in-map-name="productStoreGroupMap"/> + </if-not-empty> + <else> + <entity-and list="productStoreGroupRollups" entity-name="ProductStoreGroupRollup" filter-by-date="true"> + <field-map field-name="productStoreGroupId" from-field="productStoreGroup.productStoreGroupId"/> + <field-map field-name="parentGroupId" from-field="parameters.primaryParentGroupId"/> + </entity-and> + <if-empty field="productStoreGroupRollups"> + <set field="productStoreGroupRollupMap.productStoreGroupId" from="productStoreGroup.productStoreGroupId"/> + <set field="productStoreGroupRollupMap.parentGroupId" from="parameters.primaryParentGroupId"/> + <set field="productStoreGroupRollupMap.fromDate" from="date:nowTimestamp()"/> + <call-service service-name="createProductStoreGroupRollup" in-map-name="productStoreGroupRollupMap"/> + </if-empty> + </else> + </if-empty> + </simple-method> </simple-methods> Modified: ofbiz/branches/20120329_portletWidget/applications/product/servicedef/secas.xml URL: http://svn.apache.org/viewvc/ofbiz/branches/20120329_portletWidget/applications/product/servicedef/secas.xml?rev=1401975&r1=1401974&r2=1401975&view=diff ============================================================================== --- ofbiz/branches/20120329_portletWidget/applications/product/servicedef/secas.xml (original) +++ ofbiz/branches/20120329_portletWidget/applications/product/servicedef/secas.xml Thu Oct 25 05:04:09 2012 @@ -135,4 +135,12 @@ under the License. <action service="removeImageContentApproval" mode="sync"/> </eca> + <!-- ProductStoreGroup seca --> + <eca service="updateProductStoreGroup" event="commit"> + <condition field-name="primaryParentGroupId" operator="not-equals" value=""/> + <action service="checkProductStoreGroupRollup" mode="sync"/> + </eca> + <eca service="createProductStoreGroupRollup" event="commit"> + <action service="checkProductStoreGroupRollup" mode="sync"/> + </eca> </service-eca> Modified: ofbiz/branches/20120329_portletWidget/applications/product/servicedef/services_store.xml URL: http://svn.apache.org/viewvc/ofbiz/branches/20120329_portletWidget/applications/product/servicedef/services_store.xml?rev=1401975&r1=1401974&r2=1401975&view=diff ============================================================================== --- ofbiz/branches/20120329_portletWidget/applications/product/servicedef/services_store.xml (original) +++ ofbiz/branches/20120329_portletWidget/applications/product/servicedef/services_store.xml Thu Oct 25 05:04:09 2012 @@ -306,4 +306,47 @@ under the License. <auto-attributes include="pk" mode="IN" optional="false"/> </service> + <!--ProductStoreGroup Services --> + <service name="createProductStoreGroup" default-entity-name="ProductStoreGroup" engine="entity-auto" invoke="create" auth="true"> + <description>Create a ProductStoreGroup</description> + <auto-attributes include="pk" mode="OUT" optional="false"/> + <auto-attributes include="nonpk" mode="IN" optional="true"/> + </service> + <service name="updateProductStoreGroup" default-entity-name="ProductStoreGroup" engine="entity-auto" invoke="update" auth="true"> + <description>Update a ProductStoreGroup</description> + <auto-attributes include="pk" mode="IN" optional="false"/> + <auto-attributes include="nonpk" mode="IN" optional="true"/> + </service> + <service name="deleteProductStoreGroup" default-entity-name="ProductStoreGroup" engine="entity-auto" invoke="delete" auth="true"> + <description>Delete a ProductStoreGroup</description> + <auto-attributes include="pk" mode="IN" optional="false"/> + </service> + <service name="createProductStoreGroupMember" default-entity-name="ProductStoreGroupMember" engine="entity-auto" invoke="create" auth="true"> + <description>Create a ProductStoreGroupMember</description> + <auto-attributes include="pk" mode="IN" optional="false"/> + <auto-attributes include="nonpk" mode="IN" optional="true"/> + </service> + <service name="updateProductStoreGroupMember" default-entity-name="ProductStoreGroupMember" engine="entity-auto" invoke="update" auth="true"> + <description>Update a ProductStoreGroupMember</description> + <auto-attributes include="pk" mode="IN" optional="false"/> + <auto-attributes include="nonpk" mode="IN" optional="true"/> + </service> + <service name="createProductStoreGroupRollup" default-entity-name="ProductStoreGroupRollup" engine="entity-auto" invoke="create" auth="true"> + <description>Create a ProductStoreGroupRollup</description> + <auto-attributes include="pk" mode="IN" optional="false"/> + <auto-attributes include="nonpk" mode="IN" optional="true"/> + </service> + <service name="updateProductStoreGroupRollup" default-entity-name="ProductStoreGroupRollup" engine="entity-auto" invoke="update" auth="true"> + <description>Update a ProductStoreGroupRollup</description> + <auto-attributes include="pk" mode="IN" optional="false"/> + <auto-attributes include="nonpk" mode="IN" optional="true"/> + </service> + <service name="checkProductStoreGroupRollup" engine="simple" + location="component://product/script/org/ofbiz/product/store/ProductStoreServices.xml" invoke="checkProductStoreGroupRollup" auth="true"> + <description>Check if a productStoreGroupId with a primaryParentGroupId has related productStoreGroupRollup or for first ProductStoreGroupRollup on a ProductStoreGroup set relation on primaryParentGroupId</description> + <attribute name="productStoreGroupId" mode="IN" type="String"/> + <attribute name="primaryParentGroupId" mode="IN" type="String" optional="true"/> + <attribute name="parentGroupId" mode="IN" type="String" optional="true"/> + <attribute name="fromDate" mode="IN" type="String" optional="true"/> + </service> </services> Modified: ofbiz/branches/20120329_portletWidget/applications/product/src/org/ofbiz/product/catalog/CatalogWorker.java URL: http://svn.apache.org/viewvc/ofbiz/branches/20120329_portletWidget/applications/product/src/org/ofbiz/product/catalog/CatalogWorker.java?rev=1401975&r1=1401974&r2=1401975&view=diff ============================================================================== --- ofbiz/branches/20120329_portletWidget/applications/product/src/org/ofbiz/product/catalog/CatalogWorker.java (original) +++ ofbiz/branches/20120329_portletWidget/applications/product/src/org/ofbiz/product/catalog/CatalogWorker.java Thu Oct 25 05:04:09 2012 @@ -50,10 +50,19 @@ public class CatalogWorker { private CatalogWorker () {} + + /** + * @deprecated - Use WebSiteWorker.getWebSiteId(ServletRequest) instead + */ + @Deprecated public static String getWebSiteId(ServletRequest request) { return WebSiteWorker.getWebSiteId(request); } + /** + * @deprecated - Use WebSiteWorker.getWebSite(ServletRequest) instead + */ + @Deprecated public static GenericValue getWebSite(ServletRequest request) { return WebSiteWorker.getWebSite(request); } Modified: ofbiz/branches/20120329_portletWidget/applications/product/src/org/ofbiz/product/category/CategoryWorker.java URL: http://svn.apache.org/viewvc/ofbiz/branches/20120329_portletWidget/applications/product/src/org/ofbiz/product/category/CategoryWorker.java?rev=1401975&r1=1401974&r2=1401975&view=diff ============================================================================== --- ofbiz/branches/20120329_portletWidget/applications/product/src/org/ofbiz/product/category/CategoryWorker.java (original) +++ ofbiz/branches/20120329_portletWidget/applications/product/src/org/ofbiz/product/category/CategoryWorker.java Thu Oct 25 05:04:09 2012 @@ -434,8 +434,9 @@ public class CategoryWorker { * Its best use is to generate the trail every so often and store somewhere * (a lucene/solr tree, entities, cache or so). * - * @param productCategoryId id of category the trail should be generated for - * @returns List organized trail from root point to categoryId. + * @param dctx The DispatchContext that this service is operating in + * @param context Map containing the input parameters + * @return Map organized trail from root point to categoryId. * */ public static Map getCategoryTrail(DispatchContext dctx, Map context) { String productCategoryId = (String) context.get("productCategoryId"); Modified: ofbiz/branches/20120329_portletWidget/applications/product/src/org/ofbiz/product/config/ProductConfigWorker.java URL: http://svn.apache.org/viewvc/ofbiz/branches/20120329_portletWidget/applications/product/src/org/ofbiz/product/config/ProductConfigWorker.java?rev=1401975&r1=1401974&r2=1401975&view=diff ============================================================================== --- ofbiz/branches/20120329_portletWidget/applications/product/src/org/ofbiz/product/config/ProductConfigWorker.java (original) +++ ofbiz/branches/20120329_portletWidget/applications/product/src/org/ofbiz/product/config/ProductConfigWorker.java Thu Oct 25 05:04:09 2012 @@ -41,6 +41,7 @@ import org.ofbiz.product.config.ProductC import org.ofbiz.product.product.ProductWorker; import org.ofbiz.product.store.ProductStoreWorker; import org.ofbiz.service.LocalDispatcher; +import org.ofbiz.webapp.website.WebSiteWorker; import org.ofbiz.base.util.cache.UtilCache; /** @@ -57,7 +58,7 @@ public class ProductConfigWorker { public static ProductConfigWrapper getProductConfigWrapper(String productId, String currencyUomId, HttpServletRequest request) { ProductConfigWrapper configWrapper = null; String catalogId = CatalogWorker.getCurrentCatalogId(request); - String webSiteId = CatalogWorker.getWebSiteId(request); + String webSiteId = WebSiteWorker.getWebSiteId(request); String productStoreId = ProductStoreWorker.getProductStoreId(request); GenericValue autoUserLogin = (GenericValue)request.getSession().getAttribute("autoUserLogin"); try { Modified: ofbiz/branches/20120329_portletWidget/applications/product/src/org/ofbiz/product/store/ProductStoreWorker.java URL: http://svn.apache.org/viewvc/ofbiz/branches/20120329_portletWidget/applications/product/src/org/ofbiz/product/store/ProductStoreWorker.java?rev=1401975&r1=1401974&r2=1401975&view=diff ============================================================================== --- ofbiz/branches/20120329_portletWidget/applications/product/src/org/ofbiz/product/store/ProductStoreWorker.java (original) +++ ofbiz/branches/20120329_portletWidget/applications/product/src/org/ofbiz/product/store/ProductStoreWorker.java Thu Oct 25 05:04:09 2012 @@ -47,6 +47,7 @@ import org.ofbiz.product.product.Product import org.ofbiz.service.GenericServiceException; import org.ofbiz.service.LocalDispatcher; import org.ofbiz.service.ServiceUtil; +import org.ofbiz.webapp.website.WebSiteWorker; /** * ProductStoreWorker - Worker class for store related functionality @@ -80,7 +81,7 @@ public class ProductStoreWorker { if (session != null && session.getAttribute("productStoreId") != null) { return (String) session.getAttribute("productStoreId"); } else { - GenericValue webSite = CatalogWorker.getWebSite(request); + GenericValue webSite = WebSiteWorker.getWebSite(httpRequest); if (webSite != null) { String productStoreId = webSite.getString("productStoreId"); // might be nice to do this, but not needed and has a problem with dependencies: setSessionProductStore(productStoreId, httpRequest); Modified: ofbiz/branches/20120329_portletWidget/applications/product/webapp/catalog/WEB-INF/controller.xml URL: http://svn.apache.org/viewvc/ofbiz/branches/20120329_portletWidget/applications/product/webapp/catalog/WEB-INF/controller.xml?rev=1401975&r1=1401974&r2=1401975&view=diff ============================================================================== --- ofbiz/branches/20120329_portletWidget/applications/product/webapp/catalog/WEB-INF/controller.xml (original) +++ ofbiz/branches/20120329_portletWidget/applications/product/webapp/catalog/WEB-INF/controller.xml Thu Oct 25 05:04:09 2012 @@ -1439,6 +1439,39 @@ under the License. <response name="error" type="view" value="EditProdCatalogStores"/> </request-map> + <request-map uri="ListParentProductStoreGroup"><security https="true" auth="true"/><response name="success" type="view" value="ListParentProductStoreGroup"/></request-map> + <request-map uri="EditProductStoreGroup"><security https="true" auth="true"/><response name="success" type="view" value="EditProductStoreGroup"/></request-map> + <request-map uri="EditProductStoreGroupAndAssoc"><security https="true" auth="true"/><response name="success" type="view" value="EditProductStoreGroupAndAssoc"/></request-map> + <request-map uri="createProductStoreGroup"> + <security https="true" auth="true"/> + <event type="service" path="" invoke="createProductStoreGroup"/> + <response name="success" type="view" value="ListParentProductStoreGroup"/> + <response name="error" type="view" value="EditProductStoreGroup"/> + </request-map> + <request-map uri="updateProductStoreGroup"> + <security https="true" auth="true"/> + <event type="service" path="" invoke="updateProductStoreGroup"/> + <response name="success" type="view" value="ListParentProductStoreGroup"/> + <response name="error" type="view" value="EditProductStoreGroup"/> + </request-map> + <request-map uri="getProductStoreGroupRollupHierarchy"> + <security auth="false" https="true"/> + <event type="java" path="org.ofbiz.product.store.ProductStoreEvents" invoke="getChildProductStoreGroupTree"/> + <response name="success" type="none"/> + </request-map> + <request-map uri="AddProductStoreToGroup"> + <security auth="true" https="true"/> + <event type="service" invoke="createProductStoreGroupMember"/> + <response name="success" type="request" value="json"/> + <response name="error" type="request" value="json"/> + </request-map> + <request-map uri="updateProductStoreGroupRollup"> + <security https="true" auth="true"/> + <event type="service" path="" invoke="updateProductStoreGroupRollup"/> + <response name="success" type="view" value="ListParentProductStoreGroup"/> + <response name="error" type="view" value="EditProductStoreGroup"/> + </request-map> + <!-- ================ ProdCatalog Parties Requests ================= --> <request-map uri="EditProdCatalogParties"> <security https="true" auth="true"/> @@ -3178,6 +3211,9 @@ under the License. <view-map name="EditProductStoreFacility" page="component://product/widget/catalog/StoreScreens.xml#EditProductStoreFacility" type="screen"/> <view-map name="EditVendorProduct" type="screen" page="component://product/widget/catalog/ProductScreens.xml#EditVendorProduct"/> <view-map name="EditKeywordThesaurus" type="screen" page="component://product/widget/catalog/ThesaurusScreens.xml#EditKeywordThesaurus"/> + <view-map name="ListParentProductStoreGroup" type="screen" page="component://product/widget/catalog/StoreScreens.xml#ListParentProductStoreGroup"/> + <view-map name="EditProductStoreGroup" type="screen" page="component://product/widget/catalog/StoreScreens.xml#EditProductStoreGroup"/> + <view-map name="EditProductStoreGroupAndAssoc" type="screen" page="component://product/widget/catalog/StoreScreens.xml#EditProductStoreGroupAndAssoc"/> <view-map name="FindReviews" type="screen" page="component://product/widget/catalog/ReviewScreens.xml#FindReviews"/> Modified: ofbiz/branches/20120329_portletWidget/applications/product/webapp/catalog/find/keywordsearchbox.ftl URL: http://svn.apache.org/viewvc/ofbiz/branches/20120329_portletWidget/applications/product/webapp/catalog/find/keywordsearchbox.ftl?rev=1401975&r1=1401974&r2=1401975&view=diff ============================================================================== --- ofbiz/branches/20120329_portletWidget/applications/product/webapp/catalog/find/keywordsearchbox.ftl (original) +++ ofbiz/branches/20120329_portletWidget/applications/product/webapp/catalog/find/keywordsearchbox.ftl Thu Oct 25 05:04:09 2012 @@ -77,6 +77,7 @@ under the License. <option value="<@ofbizUrl>EditProduct</@ofbizUrl>">${uiLabelMap.ProductProduct}</option> <option value="<@ofbizUrl>EditProductPrices</@ofbizUrl>">${uiLabelMap.ProductPrices}</option> <option value="<@ofbizUrl>EditProductContent</@ofbizUrl>">${uiLabelMap.ProductContent}</option> + <option value="<@ofbizUrl>EditProductGeos</@ofbizUrl>">${uiLabelMap.ProductGeos}</option> <option value="<@ofbizUrl>EditProductGoodIdentifications</@ofbizUrl>">${uiLabelMap.CommonIds}</option> <option value="<@ofbizUrl>EditProductCategories</@ofbizUrl>">${uiLabelMap.ProductCategories}</option> <option value="<@ofbizUrl>EditProductKeyword</@ofbizUrl>">${uiLabelMap.ProductKeywords}</option> Modified: ofbiz/branches/20120329_portletWidget/applications/product/widget/catalog/CatalogMenus.xml URL: http://svn.apache.org/viewvc/ofbiz/branches/20120329_portletWidget/applications/product/widget/catalog/CatalogMenus.xml?rev=1401975&r1=1401974&r2=1401975&view=diff ============================================================================== --- ofbiz/branches/20120329_portletWidget/applications/product/widget/catalog/CatalogMenus.xml (original) +++ ofbiz/branches/20120329_portletWidget/applications/product/widget/catalog/CatalogMenus.xml Thu Oct 25 05:04:09 2012 @@ -26,6 +26,7 @@ under the License. <menu-item name="promos" title="${uiLabelMap.ProductPromos}"><link target="FindProductPromo"/></menu-item> <menu-item name="pricerules" title="${uiLabelMap.ProductPriceRules}"><link target="FindProductPriceRules"/></menu-item> <menu-item name="store" title="${uiLabelMap.ProductStores}"><link target="FindProductStore"/></menu-item> + <menu-item name="storeGroup" title="${uiLabelMap.ProductProductStoreGroups}"><link target="ListParentProductStoreGroup"/></menu-item> <menu-item name="thesaurus" title="${uiLabelMap.ProductThesaurus}"><link target="editKeywordThesaurus"/></menu-item> <menu-item name="reviews" title="${uiLabelMap.ProductReviews}"><link target="FindReviews"/></menu-item> <menu-item name="configs" title="${uiLabelMap.ProductConfigItems}"><link target="FindProductConfigItems"/></menu-item> @@ -286,6 +287,12 @@ under the License. </menu-item> </menu> + <menu name="ProductStoreGroupButtonBar" extends="CommonButtonBarMenu" extends-resource="component://common/widget/CommonMenus.xml"> + <menu-item name="editstoregroup"> + <link target="EditProductStoreGroup" text="${uiLabelMap.ProductNewGroup}" style="create"/> + </menu-item> + </menu> + <menu name="ProductStoreFacility" extends="CommonTabBarMenu" extends-resource="component://common/widget/CommonMenus.xml"> <menu-item name="AddProductStoreFacility" title="${uiLabelMap.ProductAddFacility}"> <link target="javascript:ajaxUpdateArea('ProductStoreFacilityEditArea', 'editProductStoreFacility', 'productStoreId=${parameters.productStoreId}');" Modified: ofbiz/branches/20120329_portletWidget/applications/product/widget/catalog/CommonScreens.xml URL: http://svn.apache.org/viewvc/ofbiz/branches/20120329_portletWidget/applications/product/widget/catalog/CommonScreens.xml?rev=1401975&r1=1401974&r2=1401975&view=diff ============================================================================== --- ofbiz/branches/20120329_portletWidget/applications/product/widget/catalog/CommonScreens.xml (original) +++ ofbiz/branches/20120329_portletWidget/applications/product/widget/catalog/CommonScreens.xml Thu Oct 25 05:04:09 2012 @@ -167,6 +167,37 @@ under the License. </section> </screen> + <screen name="CommonProductStoreGroupDecorator"> + <section> + <widgets> + <decorator-screen name="main-decorator" location="${parameters.mainDecoratorLocation}"> + <decorator-section name="left-column"> + <include-screen name="ProductStoreGroupTree"/> + </decorator-section> + <decorator-section name="body"> + <section> + <condition> + <or> + <if-has-permission permission="CATALOG" action="_ADMIN"/> + <if-has-permission permission="CATALOG" action="_CREATE"/> + <if-has-permission permission="CATALOG" action="_UPDATE"/> + <if-has-permission permission="CATALOG" action="_VIEW"/> + </or> + </condition> + <widgets> + <include-menu name="ProductStoreGroupButtonBar" location="component://product/widget/catalog/CatalogMenus.xml"/> + <decorator-section-include name="body"/> + </widgets> + <fail-widgets> + <label style="h3">${uiLabelMap.ProductCatalogViewPermissionError}</label> + </fail-widgets> + </section> + </decorator-section> + </decorator-screen> + </widgets> + </section> + </screen> + <screen name="CommonShippingDecorator"> <section> <widgets> @@ -323,7 +354,24 @@ under the License. </widgets> </section> </screen> - + + <screen name="ProductStoreGroupTree"> + <section> + <actions> + <entity-one value-field="parentProductStoreGroup" entity-name="ProductStoreGroup"/> + <entity-condition entity-name="ProductStoreGroup" list="parentProductStoreGroups"> + <condition-expr field-name="primaryParentGroupId" from-field="nullField"/> + </entity-condition> + </actions> + <widgets> + <screenlet id="ProductStoreGroupPanel" title="${uiLabelMap.ProductParentProductStoreGroups}" collapsible="true"> + <container id="EditDocumentTree"/> + <platform-specific><html><html-template location="component://product/webapp/catalog/store/ProductStoreGroupTree.ftl"/></html></platform-specific> + </screenlet> + </widgets> + </section> + </screen> + <screen name="main"> <section> <actions> Modified: ofbiz/branches/20120329_portletWidget/applications/product/widget/catalog/ProductForms.xml URL: http://svn.apache.org/viewvc/ofbiz/branches/20120329_portletWidget/applications/product/widget/catalog/ProductForms.xml?rev=1401975&r1=1401974&r2=1401975&view=diff ============================================================================== --- ofbiz/branches/20120329_portletWidget/applications/product/widget/catalog/ProductForms.xml (original) +++ ofbiz/branches/20120329_portletWidget/applications/product/widget/catalog/ProductForms.xml Thu Oct 25 05:04:09 2012 @@ -1884,7 +1884,7 @@ under the License. <entity-one entity-name="Enumeration" value-field="locationType"> <field-map field-name="enumId" from-field="facilityLocation.locationTypeEnumId"/> </entity-one> - <set field="showPosition1" value="${bsh:String prev=(String)previousItem.get("facilityId");return new Boolean(!(prev!=null&&prev.equals(facilityId)));}" type="Boolean"/> + <set field="showPosition1" value="${groovy:String prev=(String)previousItem.get("facilityId");return new Boolean(!(prev!=null&&prev.equals(facilityId)));}" type="Boolean"/> </row-actions> <auto-fields-service service-name="updateProductFacilityLocation" default-position="2"/> <field name="productId" position="2"><hidden/></field> Modified: ofbiz/branches/20120329_portletWidget/applications/product/widget/catalog/StoreForms.xml URL: http://svn.apache.org/viewvc/ofbiz/branches/20120329_portletWidget/applications/product/widget/catalog/StoreForms.xml?rev=1401975&r1=1401974&r2=1401975&view=diff ============================================================================== --- ofbiz/branches/20120329_portletWidget/applications/product/widget/catalog/StoreForms.xml (original) +++ ofbiz/branches/20120329_portletWidget/applications/product/widget/catalog/StoreForms.xml Thu Oct 25 05:04:09 2012 @@ -153,4 +153,99 @@ under the License. </field> <on-event-update-area event-type="submit" area-id="PrdStoreFacilityMgmtArea" area-target="ListProductStoreFacilityFormOnly?portalPortletId=PrdStoreFacilityMgmt&productStoreId=${parameters.productStoreId}"/> </form> + + <!-- ProductStoreGroup Forms --> + <form name="ListParentProductStoreGroup" type="list" target="EditProductStoreGroup" paginate="false" + odd-row-style="alternate-row" default-table-style="basic-table hover-bar"> + <actions> + <entity-condition entity-name="ProductStoreGroup"> + <condition-expr field-name="primaryParentGroupId" from-field="nullField"/> + <order-by field-name="productStoreGroupName"/> + </entity-condition> + </actions> + <field name="productStoreGroupId"><hidden/></field> + <field name="productStoreGroupName"> + <hyperlink target="ListParentProductStoreGroup" description="${productStoreGroupName} [${productStoreGroupId}]"> + <parameter param-name="productStoreGroupId"/> + </hyperlink> + </field> + <field name="productStoreGroupTypeId"><display-entity entity-name="ProductStoreGroupType"/></field> + <field name="description"><display/></field> + <field name="selectButton" title="${uiLabelMap.CommonSelect}" widget-style="smallSubmit"><submit button-type="button"/></field> + </form> + <form name="EditProductStoreGroup" target="updateProductStoreGroup" type="single" default-map-name="productStoreGroup"> + <alt-target use-when="productStoreGroup == null" target="createProductStoreGroup"/> + <auto-fields-entity entity-name="ProductStoreGroup"/> + <field name="productStoreGroupId"><hidden/></field> + <field name="productStoreGroupTypeId"> + <drop-down> + <entity-options description="${description}" entity-name="ProductStoreGroupType"/> + </drop-down> + </field> + <field name="primaryParentGroupId" use-when="productStoreGroup == null"><ignored/></field> + <field name="primaryParentGroupId" use-when="productStoreGroup != null"> + <drop-down allow-empty="true"> + <entity-options description="${productStoreGroupName} [${productStoreGroupId}]" entity-name="ProductStoreGroup" key-field-name="productStoreGroupId"> + <entity-constraint name="productStoreGroupId" operator="not-equals" env-name="productStoreGroup.productStoreGroupId"/> + </entity-options> + </drop-down> + </field> + <field name="submitButton" title="${uiLabelMap.Common${groovy: context.productStoreGroup?'Submit':'Create'}" widget-style="smallSubmit"><submit/></field> + </form> + <form name="ListProductStoreGroupAssoc" type="list" + odd-row-style="alternate-row" default-table-style="basic-table hover-bar"> + <actions> + <entity-and entity-name="ProductStoreGroupRollup" filter-by-date="true"> + <field-map field-name="parentGroupId" from-field="productStoreGroup.productStoreGroupId"/> + </entity-and> + </actions> + <field name="productStoreGroupId"> + <display-entity entity-name="ProductStoreGroup" description="${productStoreGroupName}"> + <sub-hyperlink target="EditProductStoreGroupAndAssoc" description=" [${productStoreGroupId}]"> + <parameter param-name="productStoreId"/> + </sub-hyperlink> + </display-entity> + </field> + <field name="fromDate"><display type="date"/></field> + <field name="thruDate"><display type="date"/></field> + <field name="submitButton" title=" "> + <hyperlink target="updateProductStoreGroupRollup" request-confirmation="true" description="${uiLabelMap.CommonDelete}"> + <parameter param-name="productStoreGroupId"/> + <parameter param-name="parentGroupId"/> + <parameter param-name="fromDate"/> + <parameter param-name="thruDate" from-field="date:nowTimestamp()"/> + </hyperlink> + </field> + </form> + <form name="ListProductStoreAssoc" type="list" + odd-row-style="alternate-row" default-table-style="basic-table hover-bar"> + <actions> + <entity-and entity-name="ProductStoreGroupAndMember" filter-by-date="true"> + <field-map field-name="productStoreGroupId" from-field="productStoreGroup.productStoreGroupId"/> + </entity-and> + </actions> + <field name="productStoreId"> + <hyperlink target="EditProductStore" description="${productStoreId}"> + <parameter param-name="productStoreId"/> + </hyperlink> + </field> + <field name="storeName"><display/></field> + <field name="fromDate"><display type="date"/></field> + <field name="thruDate"><display type="date"/></field> + </form> + <form name="AddProductStoreAssoc" type="single" target="AddProductStoreToGroup"> + <field name="productStoreGroupId"><hidden/></field> + <field name="productStoreId"> + <drop-down> + <entity-options description="${storeName} [${productStoreId}]" entity-name="ProductStore"> + <entity-order-by field-name="storeName"/> + </entity-options> + </drop-down> + </field> + <field name="fromDate"><date-time type="date" default-value="${nowTimestamp}"/></field> + <field name="addButton" widget-style="smallSubmit"><submit/></field> + <on-event-update-area area-target="EditProductStoreGroupAndAssoc" event-type="submit" area-id="centerdiv"> + <parameter param-name="productStoreGroupId" from-field="productStoreGroup.productStoreGroupId"/> + </on-event-update-area> + </form> </forms> Modified: ofbiz/branches/20120329_portletWidget/applications/product/widget/catalog/StoreScreens.xml URL: http://svn.apache.org/viewvc/ofbiz/branches/20120329_portletWidget/applications/product/widget/catalog/StoreScreens.xml?rev=1401975&r1=1401974&r2=1401975&view=diff ============================================================================== --- ofbiz/branches/20120329_portletWidget/applications/product/widget/catalog/StoreScreens.xml (original) +++ ofbiz/branches/20120329_portletWidget/applications/product/widget/catalog/StoreScreens.xml Thu Oct 25 05:04:09 2012 @@ -594,4 +594,65 @@ under the License. </section> </screen> + <screen name="ListParentProductStoreGroup"> + <section> + <actions> + <set field="titleProperty" value="ProductProductStoreGroup"/> + <set field="tabButtonItem" value="storeGroup"/> + </actions> + <widgets> + <decorator-screen name="CommonProductStoreGroupDecorator" location="${parameters.mainDecoratorLocation}"> + <decorator-section name="body"> + <screenlet title="${uiLabelMap.ProductParentProductStoreGroupList}"> + <include-form name="ListParentProductStoreGroup" location="component://product/widget/catalog/StoreForms.xml"/> + </screenlet> + </decorator-section> + </decorator-screen> + </widgets> + </section> + </screen> + + <screen name="EditProductStoreGroup"> + <section> + <actions> + <set field="titleProperty" value="ProductProductStoreGroup"/> + <set field="tabButtonItem" value="storeGroup"/> + <entity-one entity-name="ProductStoreGroup" value-field="productStoreGroup"/> + </actions> + <widgets> + <decorator-screen name="CommonProductStoreGroupDecorator" location="${parameters.mainDecoratorLocation}"> + <decorator-section name="body"> + <screenlet title="${uiLabelMap.ProductProductStoreGroup}"> + <include-form name="EditProductStoreGroup" location="component://product/widget/catalog/StoreForms.xml"/> + </screenlet> + </decorator-section> + </decorator-screen> + </widgets> + </section> + </screen> + + <screen name="EditProductStoreGroupAndAssoc"> + <section> + <actions> + <property-map map-name="uiLabelMap" resource="CommonUiLabels"/> + <property-map map-name="uiLabelMap" resource="ProductUiLabels"/> + <entity-one entity-name="ProductStoreGroup" value-field="productStoreGroup"/> + </actions> + <widgets> + <screenlet title="${uiLabelMap.ProductProductStoreGroup} ${productStoreGroup.productStoreGroupName} [${productStoreGroup.productStoreGroupId}]" name="editProductStoreGroup" collapsible="true" initially-collapsed="true"> + <include-form name="EditProductStoreGroup" location="component://product/widget/catalog/StoreForms.xml"/> + </screenlet> + <screenlet title="${uiLabelMap.ProductProductStoreGroupRollup}" id="editProductStoreGroupRollup" name="editProductStoreGroupRollup" collapsible="true" initially-collapsed="true"> + <include-form name="ListProductStoreGroupAssoc" location="component://product/widget/catalog/StoreForms.xml"/> + </screenlet> + <screenlet title="${uiLabelMap.ProductProductStoreMember}"> + <include-form name="ListProductStoreAssoc" location="component://product/widget/catalog/StoreForms.xml"/> + </screenlet> + <screenlet title="${uiLabelMap.ProductAddToProductStoreGroup}"> + <include-form name="AddProductStoreAssoc" location="component://product/widget/catalog/StoreForms.xml"/> + </screenlet> + </widgets> + </section> + </screen> + </screens> Modified: ofbiz/branches/20120329_portletWidget/build.xml URL: http://svn.apache.org/viewvc/ofbiz/branches/20120329_portletWidget/build.xml?rev=1401975&r1=1401974&r2=1401975&view=diff ============================================================================== --- ofbiz/branches/20120329_portletWidget/build.xml (original) +++ ofbiz/branches/20120329_portletWidget/build.xml Thu Oct 25 05:04:09 2012 @@ -1190,7 +1190,10 @@ under the License. <copy file="${basedir}/framework/resources/templates/TypeData.xml" tofile="${basedir}/hot-deploy/${component-name}/data/${component-resource-name}TypeData.xml" encoding="utf-8"> <filterset refid="replacePlaceholders"/> </copy> - <copy file="${basedir}/framework/resources/templates/SecurityData.xml" tofile="${basedir}/hot-deploy/${component-name}/data/${component-resource-name}SecurityData.xml" encoding="utf-8"> + <copy file="${basedir}/framework/resources/templates/SecurityPermissionSeedData.xml" tofile="${basedir}/hot-deploy/${component-name}/data/${component-resource-name}SecurityPermissionSeedData.xml" encoding="utf-8"> + <filterset refid="replacePlaceholders"/> + </copy> + <copy file="${basedir}/framework/resources/templates/SecurityGroupDemoData.xml" tofile="${basedir}/hot-deploy/${component-name}/data/${component-resource-name}SecurityGroupDemoData.xml" encoding="utf-8"> <filterset refid="replacePlaceholders"/> </copy> <copy file="${basedir}/framework/resources/templates/DemoData.xml" tofile="${basedir}/hot-deploy/${component-name}/data/${component-resource-name}DemoData.xml" encoding="utf-8"> Modified: ofbiz/branches/20120329_portletWidget/framework/appserver/src/org/ofbiz/appservers/GenerateContainer.java URL: http://svn.apache.org/viewvc/ofbiz/branches/20120329_portletWidget/framework/appserver/src/org/ofbiz/appservers/GenerateContainer.java?rev=1401975&r1=1401974&r2=1401975&view=diff ============================================================================== --- ofbiz/branches/20120329_portletWidget/framework/appserver/src/org/ofbiz/appservers/GenerateContainer.java (original) +++ ofbiz/branches/20120329_portletWidget/framework/appserver/src/org/ofbiz/appservers/GenerateContainer.java Thu Oct 25 05:04:09 2012 @@ -73,9 +73,7 @@ public class GenerateContainer implement private String geronimoHome = null; private String name; - /** - * @see org.ofbiz.base.container.Container#init(String[] args, String name, String configFile) - */ + @Override public void init(String[] args, String name, String configFile) { this.name = name; ofbizHome = System.getProperty("ofbiz.home"); Modified: ofbiz/branches/20120329_portletWidget/framework/base/config/cache.properties URL: http://svn.apache.org/viewvc/ofbiz/branches/20120329_portletWidget/framework/base/config/cache.properties?rev=1401975&r1=1401974&r2=1401975&view=diff ============================================================================== --- ofbiz/branches/20120329_portletWidget/framework/base/config/cache.properties (original) +++ ofbiz/branches/20120329_portletWidget/framework/base/config/cache.properties Thu Oct 25 05:04:09 2012 @@ -50,10 +50,6 @@ security.SecurityGroupPermissionCache.ex #entitycache.entity-list.default.ProductPriceRule.expireTime=0 #entitycache.entity-list.default.ProductPriceRule.useSoftReference=true -# Workflow related cache -workflow.processmgr.useSoftReference=true -workflow.client.useSoftReference=true - # product.content.rendered cache settings, set to expire in 1 minutes by default to avoid too much administrative confusion, can comment this out or increase for better performance product.content.rendered.expireTime=60000 product.content.rendered.useSoftReference=true Modified: ofbiz/branches/20120329_portletWidget/framework/base/dtd/ofbiz-properties.xsd URL: http://svn.apache.org/viewvc/ofbiz/branches/20120329_portletWidget/framework/base/dtd/ofbiz-properties.xsd?rev=1401975&r1=1401974&r2=1401975&view=diff ============================================================================== --- ofbiz/branches/20120329_portletWidget/framework/base/dtd/ofbiz-properties.xsd (original) +++ ofbiz/branches/20120329_portletWidget/framework/base/dtd/ofbiz-properties.xsd Thu Oct 25 05:04:09 2012 @@ -23,7 +23,7 @@ under the License. <xs:complexType name="valueType"> <xs:simpleContent> <xs:extension base="xs:string"> - <xs:attribute ref="xml:lang" /> + <xs:attribute ref="xml:lang" use="required"/> </xs:extension> </xs:simpleContent> </xs:complexType> Modified: ofbiz/branches/20120329_portletWidget/framework/base/src/org/ofbiz/base/config/ResourceLoader.java URL: http://svn.apache.org/viewvc/ofbiz/branches/20120329_portletWidget/framework/base/src/org/ofbiz/base/config/ResourceLoader.java?rev=1401975&r1=1401974&r2=1401975&view=diff ============================================================================== --- ofbiz/branches/20120329_portletWidget/framework/base/src/org/ofbiz/base/config/ResourceLoader.java (original) +++ ofbiz/branches/20120329_portletWidget/framework/base/src/org/ofbiz/base/config/ResourceLoader.java Thu Oct 25 05:04:09 2012 @@ -89,6 +89,8 @@ public abstract class ResourceLoader { UtilCache.clearCachesThatStartWith(xmlFilename); } + // This method should be avoided. DOM object trees take a lot of memory, so they should + // not be cached. public static Document getXmlDocument(String xmlFilename) throws GenericConfigException { Document document = (Document) loaderCache.get(xmlFilename); Modified: ofbiz/branches/20120329_portletWidget/framework/base/src/org/ofbiz/base/container/BeanShellContainer.java URL: http://svn.apache.org/viewvc/ofbiz/branches/20120329_portletWidget/framework/base/src/org/ofbiz/base/container/BeanShellContainer.java?rev=1401975&r1=1401974&r2=1401975&view=diff ============================================================================== --- ofbiz/branches/20120329_portletWidget/framework/base/src/org/ofbiz/base/container/BeanShellContainer.java (original) +++ ofbiz/branches/20120329_portletWidget/framework/base/src/org/ofbiz/base/container/BeanShellContainer.java Thu Oct 25 05:04:09 2012 @@ -38,17 +38,13 @@ public class BeanShellContainer implemen protected String name; protected int port; - /** - * @see org.ofbiz.base.container.Container#init(String[] args, String name, String configFile) - */ + @Override public void init(String[] args, String name, String configFile) { this.containerName = name; this.configFileLocation = configFile; } - /** - * @see org.ofbiz.base.container.Container#init(String[] args, String name, String configFile) - */ + @Override public boolean start() throws ContainerException { // get the container config ContainerConfig.Container cfg = ContainerConfig.getContainer(containerName, configFileLocation); Modified: ofbiz/branches/20120329_portletWidget/framework/base/src/org/ofbiz/base/container/ClassLoaderContainer.java URL: http://svn.apache.org/viewvc/ofbiz/branches/20120329_portletWidget/framework/base/src/org/ofbiz/base/container/ClassLoaderContainer.java?rev=1401975&r1=1401974&r2=1401975&view=diff ============================================================================== --- ofbiz/branches/20120329_portletWidget/framework/base/src/org/ofbiz/base/container/ClassLoaderContainer.java (original) +++ ofbiz/branches/20120329_portletWidget/framework/base/src/org/ofbiz/base/container/ClassLoaderContainer.java Thu Oct 25 05:04:09 2012 @@ -34,9 +34,7 @@ public class ClassLoaderContainer implem protected static CachedClassLoader cl = null; private String name; - /** - * @see org.ofbiz.base.container.Container#init(String[] args, String name, String configFile) - */ + @Override public void init(String[] args, String name, String configFile) throws ContainerException { this.name = name; ClassLoader parent = Thread.currentThread().getContextClassLoader(); Modified: ofbiz/branches/20120329_portletWidget/framework/base/src/org/ofbiz/base/container/ComponentContainer.java URL: http://svn.apache.org/viewvc/ofbiz/branches/20120329_portletWidget/framework/base/src/org/ofbiz/base/container/ComponentContainer.java?rev=1401975&r1=1401974&r2=1401975&view=diff ============================================================================== --- ofbiz/branches/20120329_portletWidget/framework/base/src/org/ofbiz/base/container/ComponentContainer.java (original) +++ ofbiz/branches/20120329_portletWidget/framework/base/src/org/ofbiz/base/container/ComponentContainer.java Thu Oct 25 05:04:09 2012 @@ -55,9 +55,7 @@ public class ComponentContainer implemen private String instrumenterClassName; private String instrumenterFile; - /** - * @see org.ofbiz.base.container.Container#init(String[] args, String name, String configFile) - */ + @Override public void init(String[] args, String name, String configFile) throws ContainerException { this.name = name; this.configFileLocation = configFile; Modified: ofbiz/branches/20120329_portletWidget/framework/base/src/org/ofbiz/base/container/GroovyShellContainer.java URL: http://svn.apache.org/viewvc/ofbiz/branches/20120329_portletWidget/framework/base/src/org/ofbiz/base/container/GroovyShellContainer.java?rev=1401975&r1=1401974&r2=1401975&view=diff ============================================================================== --- ofbiz/branches/20120329_portletWidget/framework/base/src/org/ofbiz/base/container/GroovyShellContainer.java (original) +++ ofbiz/branches/20120329_portletWidget/framework/base/src/org/ofbiz/base/container/GroovyShellContainer.java Thu Oct 25 05:04:09 2012 @@ -32,9 +32,6 @@ public class GroovyShellContainer implem private String configFileLocation = null; private GroovyService gsh = null; - /** - * @see org.ofbiz.base.container.Container#init(String[] args, String name, String configFile) - */ @Override public void init(String[] args, String name, String configFile) { this.name = name; Modified: ofbiz/branches/20120329_portletWidget/framework/base/src/org/ofbiz/base/container/JustLoadComponentsContainer.java URL: http://svn.apache.org/viewvc/ofbiz/branches/20120329_portletWidget/framework/base/src/org/ofbiz/base/container/JustLoadComponentsContainer.java?rev=1401975&r1=1401974&r2=1401975&view=diff ============================================================================== --- ofbiz/branches/20120329_portletWidget/framework/base/src/org/ofbiz/base/container/JustLoadComponentsContainer.java (original) +++ ofbiz/branches/20120329_portletWidget/framework/base/src/org/ofbiz/base/container/JustLoadComponentsContainer.java Thu Oct 25 05:04:09 2012 @@ -31,9 +31,7 @@ public class JustLoadComponentsContainer private String name; - /** - * @see org.ofbiz.base.container.Container#init(String[] args, String name, String configFile) - */ + @Override public void init(String[] args, String name, String configFile) { this.name = name; try { Modified: ofbiz/branches/20120329_portletWidget/framework/base/src/org/ofbiz/base/util/ScriptUtil.java URL: http://svn.apache.org/viewvc/ofbiz/branches/20120329_portletWidget/framework/base/src/org/ofbiz/base/util/ScriptUtil.java?rev=1401975&r1=1401974&r2=1401975&view=diff ============================================================================== --- ofbiz/branches/20120329_portletWidget/framework/base/src/org/ofbiz/base/util/ScriptUtil.java (original) +++ ofbiz/branches/20120329_portletWidget/framework/base/src/org/ofbiz/base/util/ScriptUtil.java Thu Oct 25 05:04:09 2012 @@ -345,7 +345,7 @@ public final class ScriptUtil { } catch (Exception e) { String errMsg = "Error running script at location [" + filePath + "]: " + e.toString(); Debug.logWarning(e, errMsg, module); - throw new IllegalArgumentException(errMsg); + throw new IllegalArgumentException(errMsg, e); } } Modified: ofbiz/branches/20120329_portletWidget/framework/base/src/org/ofbiz/base/util/UtilProperties.java URL: http://svn.apache.org/viewvc/ofbiz/branches/20120329_portletWidget/framework/base/src/org/ofbiz/base/util/UtilProperties.java?rev=1401975&r1=1401974&r2=1401975&view=diff ============================================================================== --- ofbiz/branches/20120329_portletWidget/framework/base/src/org/ofbiz/base/util/UtilProperties.java (original) +++ ofbiz/branches/20120329_portletWidget/framework/base/src/org/ofbiz/base/util/UtilProperties.java Thu Oct 25 05:04:09 2012 @@ -584,8 +584,8 @@ public class UtilProperties implements S * to the given locale and replacing argument place holders with the given arguments using the MessageFormat class * @param resource The name of the resource - can be a file, class, or URL * @param name The name of the property in the properties file - * @param locale The locale that the given resource will correspond to * @param arguments An array of Objects to insert into the message argument place holders + * @param locale The locale that the given resource will correspond to * @return The value of the property in the properties file */ public static String getMessage(String resource, String name, Object[] arguments, Locale locale) { @@ -605,8 +605,8 @@ public class UtilProperties implements S * to the given locale and replacing argument place holders with the given arguments using the MessageFormat class * @param resource The name of the resource - can be a file, class, or URL * @param name The name of the property in the properties file - * @param locale The locale that the given resource will correspond to * @param arguments A List of Objects to insert into the message argument place holders + * @param locale The locale that the given resource will correspond to * @return The value of the property in the properties file */ public static <E> String getMessage(String resource, String name, List<E> arguments, Locale locale) { @@ -630,8 +630,8 @@ public class UtilProperties implements S * to the given locale and replacing argument place holders with the given arguments using the FlexibleStringExpander class * @param resource The name of the resource - can be a file, class, or URL * @param name The name of the property in the properties file - * @param locale The locale that the given resource will correspond to * @param context A Map of Objects to insert into the message place holders using the ${} syntax of the FlexibleStringExpander + * @param locale The locale that the given resource will correspond to * @return The value of the property in the properties file */ public static String getMessage(String resource, String name, Map<String, ? extends Object> context, Locale locale) { Modified: ofbiz/branches/20120329_portletWidget/framework/base/src/org/ofbiz/base/util/UtilValidate.java URL: http://svn.apache.org/viewvc/ofbiz/branches/20120329_portletWidget/framework/base/src/org/ofbiz/base/util/UtilValidate.java?rev=1401975&r1=1401974&r2=1401975&view=diff ============================================================================== --- ofbiz/branches/20120329_portletWidget/framework/base/src/org/ofbiz/base/util/UtilValidate.java (original) +++ ofbiz/branches/20120329_portletWidget/framework/base/src/org/ofbiz/base/util/UtilValidate.java Thu Oct 25 05:04:09 2012 @@ -23,7 +23,7 @@ import com.ibm.icu.util.Calendar; import java.util.Collection; import java.util.Map; -import org.apache.commons.validator.EmailValidator; +import org.apache.commons.validator.routines.EmailValidator; import org.ofbiz.base.lang.IsEmpty; Modified: ofbiz/branches/20120329_portletWidget/framework/base/src/org/ofbiz/base/util/UtilXml.java URL: http://svn.apache.org/viewvc/ofbiz/branches/20120329_portletWidget/framework/base/src/org/ofbiz/base/util/UtilXml.java?rev=1401975&r1=1401974&r2=1401975&view=diff ============================================================================== --- ofbiz/branches/20120329_portletWidget/framework/base/src/org/ofbiz/base/util/UtilXml.java (original) +++ ofbiz/branches/20120329_portletWidget/framework/base/src/org/ofbiz/base/util/UtilXml.java Thu Oct 25 05:04:09 2012 @@ -805,7 +805,7 @@ public class UtilXml { if (node != null) { do { if (node.getNodeType() == Node.ELEMENT_NODE && (childElementName == null || - childElementName.equals(node.getNodeName()))) { + childElementName.equals(node.getLocalName() != null ? node.getLocalName() : node.getNodeName()))) { Element childElement = (Element) node; return childElement; } @@ -824,7 +824,7 @@ public class UtilXml { if (node != null) { do { if (node.getNodeType() == Node.ELEMENT_NODE && (childElementName == null || - childElementName.equals(node.getNodeName()))) { + childElementName.equals(node.getLocalName() != null ? node.getLocalName() : node.getNodeName()))) { Element childElement = (Element) node; String value = childElement.getAttribute(attrName); Modified: ofbiz/branches/20120329_portletWidget/framework/catalina/src/org/ofbiz/catalina/container/CatalinaContainer.java URL: http://svn.apache.org/viewvc/ofbiz/branches/20120329_portletWidget/framework/catalina/src/org/ofbiz/catalina/container/CatalinaContainer.java?rev=1401975&r1=1401974&r2=1401975&view=diff ============================================================================== --- ofbiz/branches/20120329_portletWidget/framework/catalina/src/org/ofbiz/catalina/container/CatalinaContainer.java (original) +++ ofbiz/branches/20120329_portletWidget/framework/catalina/src/org/ofbiz/catalina/container/CatalinaContainer.java Thu Oct 25 05:04:09 2012 @@ -173,9 +173,7 @@ public class CatalinaContainer implement private String name; - /** - * @see org.ofbiz.base.container.Container#init(String[] args, String name, String configFile) - */ + @Override public void init(String[] args, String name, String configFile) throws ContainerException { this.name = name; // get the container config @@ -548,6 +546,11 @@ public class CatalinaContainer implement connector.setProperty(prop.name, prop.value); //connector.setAttribute(prop.name, prop.value); } + + if (connectorProp.properties.containsKey("URIEncoding")) { + connector.setURIEncoding(connectorProp.properties.get("URIEncoding").value); + } + tomcat.getService().addConnector(connector); } catch (Exception e) { throw new ContainerException(e); @@ -624,21 +627,25 @@ public class CatalinaContainer implement } final String webXmlFilePath = new StringBuilder().append("file:///").append(location).append("/WEB-INF/web.xml").toString(); - - URL webXmlUrl; + boolean appIsDistributable = distribute; + URL webXmlUrl = null; try { webXmlUrl = FlexibleLocation.resolveLocation(webXmlFilePath); } catch (MalformedURLException e) { throw new ContainerException(e); } - Document webXmlDoc = null; - try { - webXmlDoc = UtilXml.readXmlDocument(webXmlUrl); - } catch (Exception e) { - throw new ContainerException(e); + File webXmlFile = new File(webXmlUrl.getFile()); + if (webXmlFile.exists()) { + Document webXmlDoc = null; + try { + webXmlDoc = UtilXml.readXmlDocument(webXmlUrl); + } catch (Exception e) { + throw new ContainerException(e); + } + appIsDistributable = webXmlDoc.getElementsByTagName("distributable").getLength() > 0; + } else { + Debug.logInfo(webXmlFilePath + " not found.", module); } - - boolean appIsDistributable = webXmlDoc.getElementsByTagName("distributable").getLength() > 0; final boolean contextIsDistributable = distribute && appIsDistributable; // configure persistent sessions Modified: ofbiz/branches/20120329_portletWidget/framework/common/config/CommonEntityLabels.xml URL: http://svn.apache.org/viewvc/ofbiz/branches/20120329_portletWidget/framework/common/config/CommonEntityLabels.xml?rev=1401975&r1=1401974&r2=1401975&view=diff ============================================================================== --- ofbiz/branches/20120329_portletWidget/framework/common/config/CommonEntityLabels.xml (original) +++ ofbiz/branches/20120329_portletWidget/framework/common/config/CommonEntityLabels.xml Thu Oct 25 05:04:09 2012 @@ -66,6 +66,7 @@ </property> <property key="CustomMethod.description.DBL_DECL_DEP_FORMULA"> <value xml:lang="en">Double decline depreciatiion algorithm for fixed asset((NetBookValue - salvageCost)*2/remainingLifeInYears)</value> + <value xml:lang="fr">Algorithme de dépréciation d'immobilisation ((valeur - coût déjà déprécié)*2/ années restantes)</value> <value xml:lang="it">Declina algoritmo doppio svalutazione per cespiti((NetBookValue - salvageCost)*2/remainingLifeInYears)</value> <value xml:lang="pt_BR">Algoritmo de deprereciação de declÃnio duplo para ativos fixos ((CustoOriginal - CustoDeRecuperação)*2/AnosRestantes)</value> <value xml:lang="vi">Thuáºt toán khấu hao chia Äôi (Double decline) áp dụng cho tà i sản cá» Äá»nh ((NetBookValue - salvageCost)*2/remainingLifeInYears)</value> @@ -74,6 +75,7 @@ </property> <property key="CustomMethod.description.STR_LINE_DEP_FORMULA"> <value xml:lang="en">Straight Line depreciatiion algorithm for fixed asset((purchaseCost - salvageCost)/expectedLifeInYears)</value> + <value xml:lang="fr">Dépréciation linéaire d'immmobilisation (valeur d'achat - coût déjà déprécié) / années d'utilisation)</value> <value xml:lang="it">Riga semplice algoritmo svalutazione per cespiti((purchaseCost - salvageCost)/expectedLifeInYears)</value> <value xml:lang="pt_BR">Algoritmo de depreciação linear para ativos fixos ((CustodeCompra - CustoDeRecuperação) / AnosDeDuraçãoEsperada)</value> <value xml:lang="vi">Thuáºt toán khấu hao 'Straight Line' áp dụng cho tà i sản cá» Äá»nh ((purchaseCost - salvageCost)/expectedLifeInYears)</value> @@ -2140,6 +2142,7 @@ <property key="Enumeration.description.PRDS_ODR_SHIP_COMPLT"> <value xml:lang="en">Shipment Complete</value> <value xml:lang="es">EnvÃo completo</value> + <value xml:lang="fr">Expédition terminée</value> <value xml:lang="it">Spedizione completata</value> <value xml:lang="pt_BR">Envio Completado</value> <value xml:lang="vi">Hoà n thà nh chuyá»n hà ng</value> @@ -2294,6 +2297,7 @@ <property key="Enumeration.description.PRDS_QUO_CREATED"> <value xml:lang="en">Quote Created</value> <value xml:lang="es">Presupuesto creado</value> + <value xml:lang="fr">Devis créé</value> <value xml:lang="it">Creazione preventivo</value> <value xml:lang="pt_BR">Cotação criada</value> <value xml:lang="vi">Tạo báo giá</value> @@ -8024,6 +8028,7 @@ <property key="StatusItem.description.CNTAP_SOFT_REJ"> <value xml:lang="en">Soft Rejected</value> <value xml:lang="es">Rechazado (admite mejoras)</value> + <value xml:lang="fr">Support rejetée</value> <value xml:lang="it">Rifiutato leggermente</value> <value xml:lang="pt_BR">Rejeitado para melhorias (Soft rejected)</value> <value xml:lang="vi">Từ chá»i má»m</value> @@ -8694,6 +8699,7 @@ <property key="StatusItem.description.FNACT_NEGPENDREPL"> <value xml:lang="en">Negative Pending Replenishment</value> <value xml:lang="es">Negativo pendiente de reposición</value> + <value xml:lang="fr">Replanification en attente</value> <value xml:lang="it">Rifornimento in attesa negativo</value> <value xml:lang="pt_BR">Reposição pendente Negativa</value> <value xml:lang="vi">Negative Pending Replenishment</value> @@ -8733,6 +8739,7 @@ <property key="StatusItem.description.HR_JS_CONTRACTOR"> <value xml:lang="en">Contractor</value> <value xml:lang="es">Contratante</value> + <value xml:lang="fr">Entrepreneur</value> <value xml:lang="it">Imprenditore</value> <value xml:lang="pt_BR">Contratante</value> <value xml:lang="vi">Ngưá»i Äấu thầu</value> Modified: ofbiz/branches/20120329_portletWidget/framework/common/config/CommonErrorUiLabels.xml URL: http://svn.apache.org/viewvc/ofbiz/branches/20120329_portletWidget/framework/common/config/CommonErrorUiLabels.xml?rev=1401975&r1=1401974&r2=1401975&view=diff ============================================================================== --- ofbiz/branches/20120329_portletWidget/framework/common/config/CommonErrorUiLabels.xml (original) +++ ofbiz/branches/20120329_portletWidget/framework/common/config/CommonErrorUiLabels.xml Thu Oct 25 05:04:09 2012 @@ -22,6 +22,7 @@ <property key="CommonErrorDublicateKey"> <value xml:lang="de">Doppelter Primärschlüssel. Der Primärschlüssel existiert bereits.</value> <value xml:lang="en">Dublicate Key. The Key already exist.</value> + <value xml:lang="fr">Clé dupliquée. Cette valeur est déjà présente.</value> <value xml:lang="vi">Khóa Äã tá»n tại và bá» trùng.</value> </property> <property key="ImageTransform.error_occurs_during_reading"> |
| Free forum by Nabble | Edit this page |
