svn commit: r810248 [13/13] - in /ofbiz/branches/executioncontext20090812: ./ applications/accounting/config/ applications/accounting/data/ applications/accounting/data/helpdata/ applications/accounting/documents/ applications/accounting/script/org/ofb...

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

svn commit: r810248 [13/13] - in /ofbiz/branches/executioncontext20090812: ./ applications/accounting/config/ applications/accounting/data/ applications/accounting/data/helpdata/ applications/accounting/documents/ applications/accounting/script/org/ofb...

adrianc
Modified: ofbiz/branches/executioncontext20090812/specialpurpose/ecommerce/webapp/ecommerce/order/orderitems.ftl
URL: http://svn.apache.org/viewvc/ofbiz/branches/executioncontext20090812/specialpurpose/ecommerce/webapp/ecommerce/order/orderitems.ftl?rev=810248&r1=810247&r2=810248&view=diff
==============================================================================
--- ofbiz/branches/executioncontext20090812/specialpurpose/ecommerce/webapp/ecommerce/order/orderitems.ftl (original)
+++ ofbiz/branches/executioncontext20090812/specialpurpose/ecommerce/webapp/ecommerce/order/orderitems.ftl Tue Sep  1 21:33:41 2009
@@ -20,281 +20,266 @@
 <#-- NOTE: this template is used for the orderstatus screen in ecommerce AND for order notification emails through the OrderNoticeEmail.ftl file -->
 <#-- the "urlPrefix" value will be prepended to URLs by the ofbizUrl transform if/when there is no "request" object in the context -->
 <#if baseEcommerceSecureUrl?exists><#assign urlPrefix = baseEcommerceSecureUrl/></#if>
-
 <div class="screenlet">
-    <div class="screenlet-header">
-        <div class="boxlink">
-            <#assign numColumns = 8>
-            <#if maySelectItems?default("N") == "Y" && roleTypeId?if_exists == "PLACING_CUSTOMER">
-                <#assign numColumns = 11>
-                <a href="javascript:document.addCommonToCartForm.add_all.value='true';document.addCommonToCartForm.submit()" class="submenutext">${uiLabelMap.OrderAddAllToCart}</a><a href="javascript:document.addCommonToCartForm.add_all.value='false';document.addCommonToCartForm.submit()" class="submenutext">${uiLabelMap.OrderAddCheckedToCart}</a><a href="<@ofbizUrl>createShoppingListFromOrder?orderId=${orderHeader.orderId}&frequency=6&intervalNumber=1&shoppingListTypeId=SLT_AUTO_REODR</@ofbizUrl>" class="submenutextright">${uiLabelMap.OrderSendMeThisEveryMonth}</a>
+  <h3>
+      <#assign numColumns = 8>
+      <#if maySelectItems?default("N") == "Y" && roleTypeId?if_exists == "PLACING_CUSTOMER">
+          <#assign numColumns = 11>
+          <a href="javascript:document.addCommonToCartForm.add_all.value='true';document.addCommonToCartForm.submit()" class="submenutext">${uiLabelMap.OrderAddAllToCart}</a><a href="javascript:document.addCommonToCartForm.add_all.value='false';document.addCommonToCartForm.submit()" class="submenutext">${uiLabelMap.OrderAddCheckedToCart}</a><a href="<@ofbizUrl>createShoppingListFromOrder?orderId=${orderHeader.orderId}&frequency=6&intervalNumber=1&shoppingListTypeId=SLT_AUTO_REODR</@ofbizUrl>" class="submenutextright">${uiLabelMap.OrderSendMeThisEveryMonth}</a>
+      </#if>
+      ${uiLabelMap.OrderOrderItems}
+  </h3>
+  <table>
+    <tr>
+      <td>${uiLabelMap.OrderProduct}</td>
+      <#if maySelectItems?default("N") == "Y">
+        <td>${uiLabelMap.OrderQtyOrdered}</td>
+        <td>${uiLabelMap.OrderQtyPicked}</td>
+        <td>${uiLabelMap.OrderQtyShipped}</td>
+        <td>${uiLabelMap.OrderQtyCanceled}</td>
+      <#else>
+        <td></td>
+        <td></td>
+        <td></td>
+        <td>${uiLabelMap.OrderQtyOrdered}</td>
+      </#if>
+      <td >${uiLabelMap.EcommerceUnitPrice}</td>
+      <td >${uiLabelMap.OrderAdjustments}</td>
+      <td >${uiLabelMap.CommonSubtotal}</td>
+      <#if maySelectItems?default("N") == "Y" && roleTypeId?if_exists == "PLACING_CUSTOMER">
+        <td colspan="3"></td>
+      </#if>
+    </tr>
+    <#list orderItems as orderItem>
+      <#-- get info from workeffort and calculate rental quantity, if it was a rental item -->
+      <#assign rentalQuantity = 1> <#-- no change if no rental item -->
+      <#if orderItem.orderItemTypeId == "RENTAL_ORDER_ITEM" && workEfforts?exists>
+        <#list workEfforts as workEffort>
+          <#if workEffort.workEffortId == orderItem.orderItemSeqId>
+            <#assign rentalQuantity = localOrderReadHelper.getWorkEffortRentalQuantity(workEffort)>
+            <#assign workEffortSave = workEffort>
+            <#break>
+          </#if>
+        </#list>
+      <#else>
+        <#assign WorkOrderItemFulfillments = orderItem.getRelated("WorkOrderItemFulfillment")?if_exists>
+        <#if WorkOrderItemFulfillments?has_content>
+          <#list WorkOrderItemFulfillments as WorkOrderItemFulfillment>
+            <#assign workEffortSave = WorkOrderItemFulfillment.getRelatedOneCache("WorkEffort")?if_exists>
+            <#break>
+           </#list>
+        </#if>
+      </#if>
+      <tr><td colspan="${numColumns}"></td></tr>
+      <tr>
+        <#if !orderItem.productId?exists || orderItem.productId == "_?_">
+          <td >
+            ${orderItem.itemDescription?default("")}
+          </td>
+        <#else>
+          <#assign product = orderItem.getRelatedOneCache("Product")?if_exists/> <#-- should always exist because of FK constraint, but just in case -->
+          <td >
+            <a href="<@ofbizUrl>product?product_id=${orderItem.productId}</@ofbizUrl>" class="linktext">${orderItem.productId} - ${orderItem.itemDescription?default("")}</a>
+            <#if product?has_content>
+              <#if product.piecesIncluded?exists && product.piecesIncluded?long != 0>
+                  [${uiLabelMap.OrderPieces}: ${product.piecesIncluded}]
+              </#if>
+              <#if (product.quantityIncluded?exists && product.quantityIncluded != 0) || product.quantityUomId?has_content>
+                <#assign quantityUom = product.getRelatedOneCache("QuantityUom")?if_exists/>
+                  [${uiLabelMap.CommonQuantity}: ${product.quantityIncluded?if_exists} ${((quantityUom.abbreviation)?default(product.quantityUomId))?if_exists}]
+              </#if>
+              <#if (product.weight?exists && product.weight != 0) || product.weightUomId?has_content>
+                <#assign weightUom = product.getRelatedOneCache("WeightUom")?if_exists/>
+                  [${uiLabelMap.CommonWeight}: ${product.weight?if_exists} ${((weightUom.abbreviation)?default(product.weightUomId))?if_exists}]
+              </#if>
+              <#if (product.productHeight?exists && product.productHeight != 0) || product.heightUomId?has_content>
+                <#assign heightUom = product.getRelatedOneCache("HeightUom")?if_exists/>
+                  [${uiLabelMap.CommonHeight}: ${product.productHeight?if_exists} ${((heightUom.abbreviation)?default(product.heightUomId))?if_exists}]
+              </#if>
+              <#if (product.productWidth?exists && product.productWidth != 0) || product.widthUomId?has_content>
+                <#assign widthUom = product.getRelatedOneCache("WidthUom")?if_exists/>
+                  [${uiLabelMap.CommonWidth}: ${product.productWidth?if_exists} ${((widthUom.abbreviation)?default(product.widthUomId))?if_exists}]
+              </#if>
+              <#if (product.productDepth?exists && product.productDepth != 0) || product.depthUomId?has_content>
+                <#assign depthUom = product.getRelatedOneCache("DepthUom")?if_exists/>
+                  [${uiLabelMap.CommonDepth}: ${product.productDepth?if_exists} ${((depthUom.abbreviation)?default(product.depthUomId))?if_exists}]
+              </#if>
             </#if>
-        </div>
-        <div class="boxhead">&nbsp; ${uiLabelMap.OrderOrderItems}</div>
-    </div>
-    <div class="screenlet-body">
-        <table width="100%" border="0" cellpadding="0">
-          <tr valign="bottom">
-            <td width="35%"><span class="tableheadtext"><b>${uiLabelMap.OrderProduct}</b></span></td>
             <#if maySelectItems?default("N") == "Y">
-              <td width="10%" align="right"><span class="tableheadtext"><b>${uiLabelMap.OrderQtyOrdered}</b></span></td>
-              <td width="10%" align="right"><span class="tableheadtext"><b>${uiLabelMap.OrderQtyPicked}</b></span></td>
-              <td width="10%" align="right"><span class="tableheadtext"><b>${uiLabelMap.OrderQtyShipped}</b></span></td>
-              <td width="10%" align="right"><span class="tableheadtext"><b>${uiLabelMap.OrderQtyCanceled}</b></span></td>
-            <#else>
-              <td width="10%" align="right">&nbsp;</td>
-              <td width="10%" align="right">&nbsp;</td>
-              <td width="10%" align="right">&nbsp;</td>
-              <td width="10%" align="right"><span class="tableheadtext"><b>${uiLabelMap.OrderQtyOrdered}</b></span></td>
-            </#if>
-            <td width="10%" align="right"><span class="tableheadtext"><b>${uiLabelMap.EcommerceUnitPrice}</b></span></td>
-            <td width="10%" align="right"><span class="tableheadtext"><b>${uiLabelMap.OrderAdjustments}</b></span></td>
-            <td width="10%" align="right"><span class="tableheadtext"><b>${uiLabelMap.CommonSubtotal}</b></span></td>
-            <#if maySelectItems?default("N") == "Y" && roleTypeId?if_exists == "PLACING_CUSTOMER">
-              <td colspan="3" width="5%" align="right">&nbsp;</td>
-            </#if>
-          </tr>
-          <#list orderItems as orderItem>
-            <#-- get info from workeffort and calculate rental quantity, if it was a rental item -->
-            <#assign rentalQuantity = 1> <#-- no change if no rental item -->
-            <#if orderItem.orderItemTypeId == "RENTAL_ORDER_ITEM" && workEfforts?exists>
-                <#list workEfforts as workEffort>
-                    <#if workEffort.workEffortId == orderItem.orderItemSeqId>
-                        <#assign rentalQuantity = localOrderReadHelper.getWorkEffortRentalQuantity(workEffort)>
-                        <#assign workEffortSave = workEffort>
-                      <#break>
-                      </#if>
-                  </#list>
-              <#else>
-                  <#assign WorkOrderItemFulfillments = orderItem.getRelated("WorkOrderItemFulfillment")?if_exists>
-                  <#if WorkOrderItemFulfillments?has_content>
-                    <#list WorkOrderItemFulfillments as WorkOrderItemFulfillment>
-                      <#assign workEffortSave = WorkOrderItemFulfillment.getRelatedOneCache("WorkEffort")?if_exists>
-                      <#break>
-                     </#list>
-                  </#if>
-            </#if>
-            <tr><td colspan="${numColumns}"><hr/></td></tr>
-            <tr>
-              <#if !orderItem.productId?exists || orderItem.productId == "_?_">
-                <td valign="top">
-                  <b><div class="tabletext"> &gt;&gt; ${orderItem.itemDescription?default("")}</div></b>
-                </td>
-              <#else>
-                <#assign product = orderItem.getRelatedOneCache("Product")?if_exists/> <#-- should always exist because of FK constraint, but just in case -->
-                <td valign="top">
-                  <div class="tabletext">
-                    <a href="<@ofbizUrl>product?product_id=${orderItem.productId}</@ofbizUrl>" class="linktext">${orderItem.productId} - ${orderItem.itemDescription?default("")}</a>
-                  </div>
-                  <div class="tabletext" style="font-size: xx-small;">
-                    <#if product?has_content>
-                      <#if product.piecesIncluded?exists && product.piecesIncluded?long != 0>
-                          [${uiLabelMap.OrderPieces}: ${product.piecesIncluded}]
-                      </#if>
-                      <#if (product.quantityIncluded?exists && product.quantityIncluded != 0) || product.quantityUomId?has_content>
-                        <#assign quantityUom = product.getRelatedOneCache("QuantityUom")?if_exists/>
-                          [${uiLabelMap.CommonQuantity}: ${product.quantityIncluded?if_exists} ${((quantityUom.abbreviation)?default(product.quantityUomId))?if_exists}]
-                      </#if>
-                      <#if (product.weight?exists && product.weight != 0) || product.weightUomId?has_content>
-                        <#assign weightUom = product.getRelatedOneCache("WeightUom")?if_exists/>
-                          [${uiLabelMap.CommonWeight}: ${product.weight?if_exists} ${((weightUom.abbreviation)?default(product.weightUomId))?if_exists}]
-                      </#if>
-                      <#if (product.productHeight?exists && product.productHeight != 0) || product.heightUomId?has_content>
-                        <#assign heightUom = product.getRelatedOneCache("HeightUom")?if_exists/>
-                          [${uiLabelMap.CommonHeight}: ${product.productHeight?if_exists} ${((heightUom.abbreviation)?default(product.heightUomId))?if_exists}]
-                      </#if>
-                      <#if (product.productWidth?exists && product.productWidth != 0) || product.widthUomId?has_content>
-                        <#assign widthUom = product.getRelatedOneCache("WidthUom")?if_exists/>
-                          [${uiLabelMap.CommonWidth}: ${product.productWidth?if_exists} ${((widthUom.abbreviation)?default(product.widthUomId))?if_exists}]
-                      </#if>
-                      <#if (product.productDepth?exists && product.productDepth != 0) || product.depthUomId?has_content>
-                        <#assign depthUom = product.getRelatedOneCache("DepthUom")?if_exists/>
-                          [${uiLabelMap.CommonDepth}: ${product.productDepth?if_exists} ${((depthUom.abbreviation)?default(product.depthUomId))?if_exists}]
-                      </#if>
-                    </#if>
-                  </div>
-                  <#if maySelectItems?default("N") == "Y">
-                    <#assign returns = orderItem.getRelated("ReturnItem")?if_exists>
-                    <#if returns?has_content>
-                      <#list returns as return>
-                        <#assign returnHeader = return.getRelatedOne("ReturnHeader")>
-                        <#if returnHeader.statusId != "RETURN_CANCELLED">
-                          <#if returnHeader.statusId == "RETURN_REQUESTED" || returnHeader.statusId == "RETURN_APPROVED">
-                            <#assign displayState = "Return Pending">
-                          <#else>
-                            <#assign displayState = "Returned">
-                          </#if>
-                          <div class="tabletext"><font color="red"><b>${displayState}</b></font> (#${return.returnId})</div>
-                        </#if>
-                      </#list>
+              <#assign returns = orderItem.getRelated("ReturnItem")?if_exists>
+              <#if returns?has_content>
+                <#list returns as return>
+                  <#assign returnHeader = return.getRelatedOne("ReturnHeader")>
+                  <#if returnHeader.statusId != "RETURN_CANCELLED">
+                    <#if returnHeader.statusId == "RETURN_REQUESTED" || returnHeader.statusId == "RETURN_APPROVED">
+                      <#assign displayState = "Return Pending">
+                    <#else>
+                      <#assign displayState = "Returned">
                     </#if>
+                    ${displayState} (#${return.returnId})
                   </#if>
-                </td>
-                <#if !(maySelectItems?default("N") == "Y")>
-                  <td>&nbsp;</td>
-                  <td>&nbsp;</td>
-                  <td>&nbsp;</td>
-                </#if>
-                <td align="right" valign="top">
-                  <div class="tabletext">${orderItem.quantity?string.number}</div>
-                </td>
-                <#if maySelectItems?default("N") == "Y">
-                <td align="right" valign="top">
-                  <#assign pickedQty = localOrderReadHelper.getItemPickedQuantityBd(orderItem)>
-                  <div class="tabletext"><#if pickedQty gt 0 && orderHeader.statusId == "ORDER_APPROVED"><font color="red">${pickedQty?default(0)?string.number}</font><#else>${pickedQty?default(0)?string.number}</#if>
-                  </div>
-                </td>
-                <td align="right" valign="top">
-                  <#assign shippedQty = localOrderReadHelper.getItemShippedQuantity(orderItem)>
-                  <div class="tabletext">${shippedQty?default(0)?string.number}</div>
-                </td>
-                <td align="right" valign="top">
-                  <#assign canceledQty = localOrderReadHelper.getItemCanceledQuantity(orderItem)>
-                  <div class="tabletext">${canceledQty?default(0)?string.number}</div>
-                </td>
-                </#if>
-                <td align="right" valign="top">
-                  <div class="tabletext"><@ofbizCurrency amount=orderItem.unitPrice isoCode=currencyUomId/></div>
-                </td>
-                <td align="right" valign="top">
-                  <div class="tabletext"><@ofbizCurrency amount=localOrderReadHelper.getOrderItemAdjustmentsTotal(orderItem) isoCode=currencyUomId/></div>
-                </td>
-                <td align="right" valign="top">
-                <#if workEfforts?exists>
-                   <div class="tabletext"><@ofbizCurrency amount=localOrderReadHelper.getOrderItemTotal(orderItem)*rentalQuantity isoCode=currencyUomId/></div>
-                <#else>
-                  <div class="tabletext"><@ofbizCurrency amount=localOrderReadHelper.getOrderItemTotal(orderItem) isoCode=currencyUomId/></div>
-                </#if>
-                </td>
-                <#if maySelectItems?default("N") == "Y" && roleTypeId?if_exists == "PLACING_CUSTOMER">
-                  <td>&nbsp;</td>
-                  <td>
-                    <input name="item_id" value="${orderItem.orderItemSeqId}" type="checkbox"/>
-                  </td>
-                  <td>&nbsp;</td>
-                </#if>
+                </#list>
               </#if>
-            </tr>
-            <#-- now cancel reason and comment field -->
-            <#if maySelectItems?default("N") == "Y" && (orderHeader.statusId != "ORDER_SENT" && orderItem.statusId != "ITEM_COMPLETED" && orderItem.statusId != "ITEM_CANCELLED" && pickedQty == 0)>
-              <tr align="right"><td colspan="7"><div class="tabletext"><b>${uiLabelMap.OrderReturnReason}</b>
-                  <select name="irm_${orderItem.orderItemSeqId}" class="selectBox">
-                    <option value="">&nbsp;</option>
-                    <#list orderItemChangeReasons as reason>
-                      <option value="${reason.enumId}">${reason.get("description",locale)?default(reason.enumId)}</option>
-                    </#list>
-                  </select>
-                  <b>${uiLabelMap.CommonComments}</b>
-                  <input class="inputBox" type="text" name="icm_${orderItem.orderItemSeqId}" value="" size="30" maxlength="60"/></div></td>
-                  <td colspan="4" align="right"><a href="javascript:document.addCommonToCartForm.action='<@ofbizUrl>cancelOrderItem</@ofbizUrl>';document.addCommonToCartForm.submit()" class="buttontext">${uiLabelMap.CommonCancel}</a>
-                    <input type="hidden" name="orderItemSeqId" value="${orderItem.orderItemSeqId}"/>
-                  </td>
-              </tr>
             </#if>
-            <#-- show info from workeffort if it was a rental item -->
-            <#if orderItem.orderItemTypeId == "RENTAL_ORDER_ITEM">
-                <#if workEffortSave?exists>
-                      <tr><td>&nbsp;</td><td colspan="${numColumns}"><div class="tabletext">${uiLabelMap.CommonFrom}: ${workEffortSave.estimatedStartDate?string("yyyy-MM-dd")} ${uiLabelMap.CommonUntil} ${workEffortSave.estimatedCompletionDate?string("yyyy-MM-dd")} ${uiLabelMap.CommonFor} ${workEffortSave.reservPersons} ${uiLabelMap.CommonPerson}(s).</div></td></tr>
-                  </#if>
+          </td>
+          <#if !(maySelectItems?default("N") == "Y")>
+            <td></td>
+            <td></td>
+            <td></td>
+          </#if>
+          <td>
+            ${orderItem.quantity?string.number}
+          </td>
+          <#if maySelectItems?default("N") == "Y">
+          <td>
+            <#assign pickedQty = localOrderReadHelper.getItemPickedQuantityBd(orderItem)>
+            <#if pickedQty gt 0 && orderHeader.statusId == "ORDER_APPROVED">${pickedQty?default(0)?string.number}<#else>${pickedQty?default(0)?string.number}</#if>
+          </td>
+          <td>
+            <#assign shippedQty = localOrderReadHelper.getItemShippedQuantity(orderItem)>
+            ${shippedQty?default(0)?string.number}
+          </td>
+          <td>
+            <#assign canceledQty = localOrderReadHelper.getItemCanceledQuantity(orderItem)>
+            ${canceledQty?default(0)?string.number}
+          </td>
+          </#if>
+          <td>
+            <@ofbizCurrency amount=orderItem.unitPrice isoCode=currencyUomId/>
+          </td>
+          <td>
+            <@ofbizCurrency amount=localOrderReadHelper.getOrderItemAdjustmentsTotal(orderItem) isoCode=currencyUomId/>
+          </td>
+          <td>
+            <#if workEfforts?exists>
+              <@ofbizCurrency amount=localOrderReadHelper.getOrderItemTotal(orderItem)*rentalQuantity isoCode=currencyUomId/>
+            <#else>
+              <@ofbizCurrency amount=localOrderReadHelper.getOrderItemTotal(orderItem) isoCode=currencyUomId/>
             </#if>
-            <#-- now show adjustment details per line item -->
-            <#assign itemAdjustments = localOrderReadHelper.getOrderItemAdjustments(orderItem)>
-            <#list itemAdjustments as orderItemAdjustment>
-              <tr>
-                <td align="right">
-                  <div class="tabletext" style="font-size: xx-small;">
-                    <b><i>${uiLabelMap.EcommerceAdjustment}</i>:</b> <b>${localOrderReadHelper.getAdjustmentType(orderItemAdjustment)}</b>&nbsp;
-                    <#if orderItemAdjustment.description?has_content>: ${orderItemAdjustment.description}</#if>
-
-                    <#if orderItemAdjustment.orderAdjustmentTypeId == "SALES_TAX">
-                      <#if orderItemAdjustment.primaryGeoId?has_content>
-                        <#assign primaryGeo = orderItemAdjustment.getRelatedOneCache("PrimaryGeo")/>
-                        <#if primaryGeo.geoName?has_content>
-                            <b>${uiLabelMap.OrderJurisdiction}:</b> ${primaryGeo.geoName} [${primaryGeo.abbreviation?if_exists}]
-                        </#if>
-                        <#if orderItemAdjustment.secondaryGeoId?has_content>
-                          <#assign secondaryGeo = orderItemAdjustment.getRelatedOneCache("SecondaryGeo")/>
-                          (<b>${uiLabelMap.CommonIn}:</b> ${secondaryGeo.geoName} [${secondaryGeo.abbreviation?if_exists}])
-                        </#if>
-                      </#if>
-                      <#if orderItemAdjustment.sourcePercentage?exists><b>${uiLabelMap.EcommerceRate}:</b> ${orderItemAdjustment.sourcePercentage}</#if>
-                      <#if orderItemAdjustment.customerReferenceId?has_content><b>${uiLabelMap.OrderCustomerTaxId}:</b> ${orderItemAdjustment.customerReferenceId}</#if>
-                      <#if orderItemAdjustment.exemptAmount?exists><b>${uiLabelMap.EcommerceExemptAmount}:</b> ${orderItemAdjustment.exemptAmount}</#if>
-                    </#if>
-                  </div>
-                </td>
-                <td colspan="5">&nbsp;</td>
-                <td align="right">
-                  <div class="tabletext" style="font-size: xx-small;"><@ofbizCurrency amount=localOrderReadHelper.getOrderItemAdjustmentTotal(orderItem, orderItemAdjustment) isoCode=currencyUomId/></div>
-                </td>
-                <td>&nbsp;</td>
-                <#if maySelectItems?default("N") == "Y"><td colspan="3">&nbsp;</td></#if>
-              </tr>
-            </#list>
-
-            <#-- show the order item ship group info -->
-            <#assign orderItemShipGroupAssocs = orderItem.getRelated("OrderItemShipGroupAssoc")?if_exists>
-            <#if orderItemShipGroupAssocs?has_content>
-              <#list orderItemShipGroupAssocs as shipGroupAssoc>
-                <#assign shipGroup = shipGroupAssoc.getRelatedOne("OrderItemShipGroup")?if_exists>
-                <#assign shipGroupAddress = (shipGroup.getRelatedOne("PostalAddress"))?if_exists>
-                <tr>
-                  <td align="right">
-                    <div class="tabletext" style="font-size: xx-small;"><b><i>${uiLabelMap.OrderShipGroup}</i>:</b> [${shipGroup.shipGroupSeqId}] ${shipGroupAddress.address1?default("N/A")}</div>
-                  </td>
-                  <td align="right">
-                    <div class="tabletext" style="font-size: xx-small;">${shipGroupAssoc.quantity?string.number}</div>
-                  </td>
-                  <td colspan="${numColumns - 2}">&nbsp;</td>
-                </tr>
+          </td>
+          <#if maySelectItems?default("N") == "Y" && roleTypeId?if_exists == "PLACING_CUSTOMER">
+            <td></td>
+            <td>
+              <input name="item_id" value="${orderItem.orderItemSeqId}" type="checkbox"/>
+            </td>
+            <td></td>
+          </#if>
+        </#if>
+      </tr>
+      <#-- now cancel reason and comment field -->
+      <#if maySelectItems?default("N") == "Y" && (orderHeader.statusId != "ORDER_SENT" && orderItem.statusId != "ITEM_COMPLETED" && orderItem.statusId != "ITEM_CANCELLED" && pickedQty == 0)>
+        <tr>
+          <td colspan="7">${uiLabelMap.OrderReturnReason}
+            <select name="irm_${orderItem.orderItemSeqId}" class="selectBox">
+              <option value=""></option>
+              <#list orderItemChangeReasons as reason>
+                <option value="${reason.enumId}">${reason.get("description",locale)?default(reason.enumId)}</option>
               </#list>
+            </select>
+            ${uiLabelMap.CommonComments}
+            <input class="inputBox" type="text" name="icm_${orderItem.orderItemSeqId}" value="" size="30" maxlength="60"/>
+          </td>
+          <td colspan="4"><a href="javascript:document.addCommonToCartForm.action='<@ofbizUrl>cancelOrderItem</@ofbizUrl>';document.addCommonToCartForm.submit()" class="buttontext">${uiLabelMap.CommonCancel}</a>
+            <input type="hidden" name="orderItemSeqId" value="${orderItem.orderItemSeqId}"/>
+          </td>
+        </tr>
+      </#if>
+      <#-- show info from workeffort if it was a rental item -->
+      <#if orderItem.orderItemTypeId == "RENTAL_ORDER_ITEM">
+        <#if workEffortSave?exists>
+          <tr><td></td><td colspan="${numColumns}">${uiLabelMap.CommonFrom}: ${workEffortSave.estimatedStartDate?string("yyyy-MM-dd")} ${uiLabelMap.CommonUntil} ${workEffortSave.estimatedCompletionDate?string("yyyy-MM-dd")} ${uiLabelMap.CommonFor} ${workEffortSave.reservPersons} ${uiLabelMap.CommonPerson}(s)</td></tr>
+        </#if>
+      </#if>
+      <#-- now show adjustment details per line item -->
+      <#assign itemAdjustments = localOrderReadHelper.getOrderItemAdjustments(orderItem)>
+      <#list itemAdjustments as orderItemAdjustment>
+        <tr>
+          <td>
+            ${uiLabelMap.EcommerceAdjustment}: ${localOrderReadHelper.getAdjustmentType(orderItemAdjustment)}
+            <#if orderItemAdjustment.description?has_content>: ${orderItemAdjustment.description}</#if>
+            <#if orderItemAdjustment.orderAdjustmentTypeId == "SALES_TAX">
+              <#if orderItemAdjustment.primaryGeoId?has_content>
+                <#assign primaryGeo = orderItemAdjustment.getRelatedOneCache("PrimaryGeo")/>
+                <#if primaryGeo.geoName?has_content>
+                  ${uiLabelMap.OrderJurisdiction}: ${primaryGeo.geoName} [${primaryGeo.abbreviation?if_exists}]
+                </#if>
+                <#if orderItemAdjustment.secondaryGeoId?has_content>
+                  <#assign secondaryGeo = orderItemAdjustment.getRelatedOneCache("SecondaryGeo")/>
+                  (${uiLabelMap.CommonIn}: ${secondaryGeo.geoName} [${secondaryGeo.abbreviation?if_exists}])
+                </#if>
+              </#if>
+              <#if orderItemAdjustment.sourcePercentage?exists>${uiLabelMap.EcommerceRate}: ${orderItemAdjustment.sourcePercentage}</#if>
+              <#if orderItemAdjustment.customerReferenceId?has_content>${uiLabelMap.OrderCustomerTaxId}: ${orderItemAdjustment.customerReferenceId}</#if>
+              <#if orderItemAdjustment.exemptAmount?exists>${uiLabelMap.EcommerceExemptAmount}: ${orderItemAdjustment.exemptAmount}</#if>
             </#if>
-
-           </#list>
-           <#if orderItems?size == 0 || !orderItems?has_content>
-             <tr><td colspan="${numColumns}"><font color="red">${uiLabelMap.OrderSalesOrderLookupFailed}</font></td></tr>
-           </#if>
-
-          <tr><td colspan="${numColumns}"><hr/></td></tr>
-          <tr>
-            <td align="right" colspan="7"><div class="tabletext"><b>${uiLabelMap.CommonSubtotal}</b></div></td>
-            <td align="right"><div class="tabletext"><@ofbizCurrency amount=orderSubTotal isoCode=currencyUomId/></div></td>
-            <#if maySelectItems?default("N") == "Y"><td colspan="3">&nbsp;</td></#if>
-          </tr>
-          <#list headerAdjustmentsToShow as orderHeaderAdjustment>
-            <tr>
-              <td align="right" colspan="7"><div class="tabletext"><b>${localOrderReadHelper.getAdjustmentType(orderHeaderAdjustment)}</b></div></td>
-              <td align="right"><div class="tabletext"><@ofbizCurrency amount=localOrderReadHelper.getOrderAdjustmentTotal(orderHeaderAdjustment) isoCode=currencyUomId/></div></td>
-              <#if maySelectItems?default("N") == "Y"><td colspan="3">&nbsp;</td></#if>
-            </tr>
-          </#list>
-          <tr>
-            <td align="right" colspan="7"><div class="tabletext"><b>${uiLabelMap.OrderShippingAndHandling}</b></div></td>
-            <td align="right"><div class="tabletext"><@ofbizCurrency amount=orderShippingTotal isoCode=currencyUomId/></div></td>
-            <#if maySelectItems?default("N") == "Y"><td colspan="3">&nbsp;</td></#if>
-          </tr>
-          <tr>
-            <td align="right" colspan="7"><div class="tabletext"><b>${uiLabelMap.OrderSalesTax}</b></div></td>
-            <td align="right"><div class="tabletext"><@ofbizCurrency amount=orderTaxTotal isoCode=currencyUomId/></div></td>
-            <#if maySelectItems?default("N") == "Y"><td colspan="3">&nbsp;</td></#if>
-          </tr>
-
-          <tr>
-            <td colspan="3"></td>
-            <#if maySelectItems?default("N") == "Y">
-                <td colspan="${numColumns - 6}"><hr/></td>
-                <td colspan="3">&nbsp;</td>
-            <#else>
-                <td colspan="${numColumns - 3}"><hr/></td>
-            </#if>
-          </tr>
+          </td>
+          <td colspan="5"></td>
+          <td>
+            <@ofbizCurrency amount=localOrderReadHelper.getOrderItemAdjustmentTotal(orderItem, orderItemAdjustment) isoCode=currencyUomId/>
+          </td>
+          <td></td>
+          <#if maySelectItems?default("N") == "Y"><td colspan="3"></td></#if>
+        </tr>
+      </#list>
+      <#-- show the order item ship group info -->
+      <#assign orderItemShipGroupAssocs = orderItem.getRelated("OrderItemShipGroupAssoc")?if_exists>
+      <#if orderItemShipGroupAssocs?has_content>
+        <#list orderItemShipGroupAssocs as shipGroupAssoc>
+          <#assign shipGroup = shipGroupAssoc.getRelatedOne("OrderItemShipGroup")?if_exists>
+          <#assign shipGroupAddress = (shipGroup.getRelatedOne("PostalAddress"))?if_exists>
           <tr>
-            <td align="right" colspan="7"><div class="tabletext"><b>${uiLabelMap.OrderGrandTotal}</b></div></td>
-            <td align="right">
-              <div class="tabletext"><@ofbizCurrency amount=orderGrandTotal isoCode=currencyUomId/></div>
+            <td>
+              ${uiLabelMap.OrderShipGroup}: [${shipGroup.shipGroupSeqId}] ${shipGroupAddress.address1?default("N/A")}
+            </td>
+            <td>
+              ${shipGroupAssoc.quantity?string.number}
             </td>
-            <#if maySelectItems?default("N") == "Y"><td colspan="3">&nbsp;</td></#if>
+            <td colspan="${numColumns - 2}"></td>
           </tr>
-        </table>
-    </div>
+        </#list>
+      </#if>
+    </#list>
+    <#if orderItems?size == 0 || !orderItems?has_content>
+      <tr><td colspan="${numColumns}">${uiLabelMap.OrderSalesOrderLookupFailed}</td></tr>
+    </#if>
+    <tr><td colspan="${numColumns}"></td></tr>
+    <tr>
+      <td colspan="7">${uiLabelMap.CommonSubtotal}</td>
+      <td><@ofbizCurrency amount=orderSubTotal isoCode=currencyUomId/></td>
+      <#if maySelectItems?default("N") == "Y"><td colspan="3"></td></#if>
+    </tr>
+    <#list headerAdjustmentsToShow as orderHeaderAdjustment>
+      <tr>
+        <td colspan="7">${localOrderReadHelper.getAdjustmentType(orderHeaderAdjustment)}</td>
+        <td><@ofbizCurrency amount=localOrderReadHelper.getOrderAdjustmentTotal(orderHeaderAdjustment) isoCode=currencyUomId/></td>
+        <#if maySelectItems?default("N") == "Y"><td colspan="3"></td></#if>
+      </tr>
+    </#list>
+    <tr>
+      <td colspan="7">${uiLabelMap.OrderShippingAndHandling}</td>
+      <td><@ofbizCurrency amount=orderShippingTotal isoCode=currencyUomId/></td>
+      <#if maySelectItems?default("N") == "Y"><td colspan="3"></td></#if>
+    </tr>
+    <tr>
+      <td colspan="7">${uiLabelMap.OrderSalesTax}</td>
+      <td><@ofbizCurrency amount=orderTaxTotal isoCode=currencyUomId/></td>
+      <#if maySelectItems?default("N") == "Y"><td colspan="3"></td></#if>
+    </tr>
+    <tr>
+      <td colspan="3"></td>
+      <#if maySelectItems?default("N") == "Y">
+        <td colspan="${numColumns - 6}"></td>
+        <td colspan="3"></td>
+      <#else>
+        <td colspan="${numColumns - 3}"></td>
+      </#if>
+    </tr>
+    <tr>
+      <td colspan="7">${uiLabelMap.OrderGrandTotal}</td>
+      <td>
+        <@ofbizCurrency amount=orderGrandTotal isoCode=currencyUomId/>
+      </td>
+      <#if maySelectItems?default("N") == "Y"><td colspan="3"></td></#if>
+    </tr>
+  </table>
 </div>

Modified: ofbiz/branches/executioncontext20090812/specialpurpose/ecommerce/widget/blog/BlogForms.xml
URL: http://svn.apache.org/viewvc/ofbiz/branches/executioncontext20090812/specialpurpose/ecommerce/widget/blog/BlogForms.xml?rev=810248&r1=810247&r2=810248&view=diff
==============================================================================
--- ofbiz/branches/executioncontext20090812/specialpurpose/ecommerce/widget/blog/BlogForms.xml (original)
+++ ofbiz/branches/executioncontext20090812/specialpurpose/ecommerce/widget/blog/BlogForms.xml Tue Sep  1 21:33:41 2009
@@ -63,6 +63,8 @@
             <service service-name="performFind" result-map-list="listIt">
                 <field-map field-name="inputFields" from-field="requestParameters"/>
                 <field-map field-name="entityName" from-field="entityName"/>
+                <field-map field-name="viewIndex" from-field="viewIndex"/>
+                <field-map field-name="viewSize" from-field="viewSize"/>
             </service>
         </actions>
 

Modified: ofbiz/branches/executioncontext20090812/specialpurpose/googlebase/config/GoogleBaseUiLabels.xml
URL: http://svn.apache.org/viewvc/ofbiz/branches/executioncontext20090812/specialpurpose/googlebase/config/GoogleBaseUiLabels.xml?rev=810248&r1=810247&r2=810248&view=diff
==============================================================================
--- ofbiz/branches/executioncontext20090812/specialpurpose/googlebase/config/GoogleBaseUiLabels.xml (original)
+++ ofbiz/branches/executioncontext20090812/specialpurpose/googlebase/config/GoogleBaseUiLabels.xml Tue Sep  1 21:33:41 2009
@@ -61,6 +61,9 @@
         <value xml:lang="th">Web Site Url</value>
         <value xml:lang="zh">网站网址</value>
     </property>
+    <property key="GoogleBaseAddGoogleBaseConfiguration">
+        <value xml:lang="en">Add Google Base Configuration</value>
+    </property>
     <property key="GoogleBaseApplication">
         <value xml:lang="en">Google Base Integration</value>
         <value xml:lang="fr">Intégration de Google Base</value>
@@ -74,6 +77,9 @@
         <value xml:lang="it">Ofbiz</value>
         <value xml:lang="th">Ofbiz</value>
     </property>
+    <property key="GoogleBaseConfiguration">
+        <value xml:lang="en">Google Base Configurations</value>
+    </property>
     <property key="GoogleBaseExportCountryCode">
         <value xml:lang="en">Select your country destination</value>
         <value xml:lang="fr">Sélectionner votre pays de destination</value>

Modified: ofbiz/branches/executioncontext20090812/specialpurpose/googlebase/data/GoogleBaseTypeData.xml
URL: http://svn.apache.org/viewvc/ofbiz/branches/executioncontext20090812/specialpurpose/googlebase/data/GoogleBaseTypeData.xml?rev=810248&r1=810247&r2=810248&view=diff
==============================================================================
--- ofbiz/branches/executioncontext20090812/specialpurpose/googlebase/data/GoogleBaseTypeData.xml (original)
+++ ofbiz/branches/executioncontext20090812/specialpurpose/googlebase/data/GoogleBaseTypeData.xml Tue Sep  1 21:33:41 2009
@@ -21,5 +21,5 @@
 <entity-engine-xml>
 
     <GoodIdentificationType description="Google Id" goodIdentificationTypeId="GOOGLE_ID" hasTable="N" parentTypeId=""/>
-
+    <WebSite webSiteId="GOOGLEBASE" siteName="Google Base Application" visualThemeSetId="BACKOFFICE"/>
 </entity-engine-xml>

Modified: ofbiz/branches/executioncontext20090812/specialpurpose/googlebase/ofbiz-component.xml
URL: http://svn.apache.org/viewvc/ofbiz/branches/executioncontext20090812/specialpurpose/googlebase/ofbiz-component.xml?rev=810248&r1=810247&r2=810248&view=diff
==============================================================================
--- ofbiz/branches/executioncontext20090812/specialpurpose/googlebase/ofbiz-component.xml (original)
+++ ofbiz/branches/executioncontext20090812/specialpurpose/googlebase/ofbiz-component.xml Tue Sep  1 21:33:41 2009
@@ -25,8 +25,10 @@
     <classpath type="dir" location="config"/>
     <classpath type="jar" location="build/lib/*"/>
 
+    <entity-resource type="model" reader-name="main" loader="main" location="entitydef/entitymodel.xml"/>
     <entity-resource type="data" reader-name="seed" loader="main" location="data/GoogleBaseTypeData.xml"/>
     <entity-resource type="data" reader-name="seed" loader="main" location="data/GoogleBaseSecurityData.xml"/>
+    <entity-resource type="data" reader-name="demo" loader="main" location="data/DemoGoogleBaseData.xml"/>
 
     <service-resource type="model" loader="main" location="servicedef/services.xml"/>
 

Modified: ofbiz/branches/executioncontext20090812/specialpurpose/googlebase/servicedef/services.xml
URL: http://svn.apache.org/viewvc/ofbiz/branches/executioncontext20090812/specialpurpose/googlebase/servicedef/services.xml?rev=810248&r1=810247&r2=810248&view=diff
==============================================================================
--- ofbiz/branches/executioncontext20090812/specialpurpose/googlebase/servicedef/services.xml (original)
+++ ofbiz/branches/executioncontext20090812/specialpurpose/googlebase/servicedef/services.xml Tue Sep  1 21:33:41 2009
@@ -36,6 +36,7 @@
         <attribute type="String" mode="IN" name="trackingCodeId" optional="true"/>
         <attribute type="String" mode="IN" name="webSiteMountPoint" optional="false"/>
         <attribute type="String" mode="IN" name="countryCode" optional="false"/>
+        <attribute type="String" mode="IN" name="productStoreId" optional="true"/>
     </service>
     <service name="exportProductCategoryToGoogle" engine="java"
              location="org.ofbiz.googlebase.ProductsExportToGoogle" invoke="exportProductCategoryToGoogle" auth="true">
@@ -45,4 +46,21 @@
         <attribute type="String" mode="IN" name="webSiteUrl" optional="false"/>
         <attribute type="String" mode="IN" name="imageUrl" optional="true"/>
     </service>
+    
+    <!-- Start configuration services -->
+    <service name="createGoogleBaseConfig" default-entity-name="GoogleBaseConfig" engine="entity-auto" invoke="create" auth="true">
+        <description>Create a GoogleBaseConfig</description>
+        <auto-attributes include="pk" mode="IN" optional="false"/>
+        <auto-attributes include="nonpk" mode="IN" optional="true"/>
+    </service>
+    <service name="updateGoogleBaseConfig" default-entity-name="GoogleBaseConfig" engine="entity-auto" invoke="update" auth="true">
+        <description>Update a GoogleBaseConfig</description>
+        <auto-attributes include="pk" mode="IN" optional="false"/>
+        <auto-attributes include="nonpk" mode="IN" optional="true"/>
+    </service>
+    <service name="deleteGoogleBaseConfig" default-entity-name="GoogleBaseConfig" engine="entity-auto" invoke="delete" auth="true">
+        <description>Delete a GoogleBaseConfig</description>
+        <auto-attributes include="pk" mode="IN" optional="false"/>
+    </service>
+    
 </services>

Modified: ofbiz/branches/executioncontext20090812/specialpurpose/googlebase/src/org/ofbiz/googlebase/GoogleBaseSearchEvents.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/executioncontext20090812/specialpurpose/googlebase/src/org/ofbiz/googlebase/GoogleBaseSearchEvents.java?rev=810248&r1=810247&r2=810248&view=diff
==============================================================================
--- ofbiz/branches/executioncontext20090812/specialpurpose/googlebase/src/org/ofbiz/googlebase/GoogleBaseSearchEvents.java (original)
+++ ofbiz/branches/executioncontext20090812/specialpurpose/googlebase/src/org/ofbiz/googlebase/GoogleBaseSearchEvents.java Tue Sep  1 21:33:41 2009
@@ -90,6 +90,7 @@
                 String trackingCodeId = (String) request.getParameter("trackingCodeId");
                 String webSiteMountPoint = (String) request.getParameter("webSiteMountPoint");
                 String countryCode = (String) request.getParameter("countryCode");
+                String productStoreId = (String) request.getParameter("productStoreId");
 
                 // Export all or selected products to Google Base
                 try {
@@ -103,6 +104,7 @@
                                                "countryCode", countryCode);
                     inMap.put("trackingCodeId", trackingCodeId);
                     inMap.put("userLogin", userLogin);
+                    inMap.put("productStoreId", productStoreId);
                     Map exportResult = dispatcher.runSync("exportToGoogle", inMap);
                     if (ServiceUtil.isError(exportResult)) {
                         List errorMessages = (List)exportResult.get(ModelService.ERROR_MESSAGE_LIST);

Modified: ofbiz/branches/executioncontext20090812/specialpurpose/googlebase/src/org/ofbiz/googlebase/ProductsExportToGoogle.java
URL: http://svn.apache.org/viewvc/ofbiz/branches/executioncontext20090812/specialpurpose/googlebase/src/org/ofbiz/googlebase/ProductsExportToGoogle.java?rev=810248&r1=810247&r2=810248&view=diff
==============================================================================
--- ofbiz/branches/executioncontext20090812/specialpurpose/googlebase/src/org/ofbiz/googlebase/ProductsExportToGoogle.java (original)
+++ ofbiz/branches/executioncontext20090812/specialpurpose/googlebase/src/org/ofbiz/googlebase/ProductsExportToGoogle.java Tue Sep  1 21:33:41 2009
@@ -52,6 +52,7 @@
 import org.ofbiz.service.LocalDispatcher;
 import org.ofbiz.service.ModelService;
 import org.ofbiz.service.ServiceUtil;
+import org.ofbiz.base.util.StringUtil;
 import org.w3c.dom.Document;
 import org.w3c.dom.Element;
 
@@ -59,6 +60,11 @@
 
     private static final String resource = "GoogleBaseUiLabels";
     private static final String module = ProductsExportToGoogle.class.getName();
+    private static final String googleBaseNSUrl = "http://base.google.com/ns/1.0";
+    private static final String googleBaseBatchUrl = "http://schemas.google.com/gdata/batch";
+    private static final String googleBaseMetadataUrl = "http://base.google.com/ns-metadata/1.0";
+    private static final String googleBaseAppUrl = "http://purl.org/atom/app#";
+    private static final String configString = "googleBaseExport.properties";
 
     public static Map exportToGoogle(DispatchContext dctx, Map context) {
         Locale locale = (Locale) context.get("locale");
@@ -67,30 +73,14 @@
 
         Map result = null;
         try {
-            String configString = "googleBaseExport.properties";
-
-            // get the Developer Key
-            String developerKey = UtilProperties.getPropertyValue(configString, "googleBaseExport.developerKey");
-
-            // get the Authentication Url
-            String authenticationUrl = UtilProperties.getPropertyValue(configString, "googleBaseExport.authenticationUrl");
-
-            // get the Google Account Email
-            String accountEmail = UtilProperties.getPropertyValue(configString, "googleBaseExport.accountEmail");
-
-            // get the Google Account Password
-            String accountPassword = UtilProperties.getPropertyValue(configString, "googleBaseExport.accountPassword");
-
-            // get the Url to Post Items
-            String postItemsUrl = UtilProperties.getPropertyValue(configString, "googleBaseExport.postItemsUrl");
-
+            Map<String, Object> googleBaseConfigResult = buildGoogleBaseConfig(context, delegator);
             StringBuffer dataItemsXml = new StringBuffer();
 
             result = buildDataItemsXml(dctx, context, dataItemsXml);
-            if (!ServiceUtil.isFailure(result)) {
-                String token = authenticate(authenticationUrl, accountEmail, accountPassword);
+            if (!ServiceUtil.isFailure(result) && UtilValidate.isNotEmpty(googleBaseConfigResult)) {
+                String token = authenticate(googleBaseConfigResult.get("authenticationUrl").toString(), googleBaseConfigResult.get("accountEmail").toString(), googleBaseConfigResult.get("accountPassword").toString());
                 if (token != null) {
-                    result = postItem(token, postItemsUrl, developerKey, dataItemsXml, locale, (String)context.get("testMode"), (List)result.get("newProductsInGoogle"), (List)result.get("productsRemovedFromGoogle"), dispatcher, delegator);
+                    result = postItem(token, googleBaseConfigResult.get("postItemsUrl").toString(), googleBaseConfigResult.get("developerKey").toString(), dataItemsXml, locale, (String)context.get("testMode"), (List)result.get("newProductsInGoogle"), (List)result.get("productsRemovedFromGoogle"), dispatcher, delegator);
                 } else {
                     Debug.logError("Error during authentication to Google Account", module);
                     return ServiceUtil.returnFailure(UtilProperties.getMessage(resource, "productsExportToGoogle.errorDuringAuthenticationToGoogle", locale));
@@ -362,6 +352,7 @@
             feedElem.setAttribute("xmlns", "http://www.w3.org/2005/Atom");
             feedElem.setAttribute("xmlns:openSearch", "http://a9.com/-/spec/opensearchrss/1.0/");
             feedElem.setAttribute("xmlns:g", "http://base.google.com/ns/1.0");
+            feedElem.setAttribute("xmlns:gm", "http://base.google.com/ns-metadata/1.0");
             feedElem.setAttribute("xmlns:batch", "http://schemas.google.com/gdata/batch");
             feedElem.setAttribute("xmlns:app", "http://purl.org/atom/app#");
 
@@ -381,7 +372,13 @@
                 // TODO: improve this (i.e. get the relative path from the properies file)
                 String link = webSiteUrl + "/"+webSiteMountPoint+"/control/product/~product_id=" + prod.getString("productId") + trackingCodeId;
                 String title = UtilFormatOut.encodeXmlValue(prod.getString("productName"));
+                if (UtilValidate.isEmpty(title)) {
+                    title = UtilFormatOut.encodeXmlValue(prod.getString("internalName"));
+                }
                 String description = UtilFormatOut.encodeXmlValue(prod.getString("description"));
+                if (UtilValidate.isEmpty(description)) {
+                    description = UtilFormatOut.encodeXmlValue(prod.getString("internalName"));
+                }
                 String imageLink = "";
                 if (UtilValidate.isNotEmpty(prod.getString("largeImageUrl"))) {
                     imageLink = webSiteUrl + prod.getString("largeImageUrl");
@@ -406,17 +403,23 @@
                     itemActionType = "insert";
                 }
                 Element entryElem = UtilXml.addChildElement(feedElem, "entry", feedDocument);
-                Element batchElem = UtilXml.addChildElement(entryElem, "batch:operation", feedDocument);
-                batchElem.setAttribute("type", itemActionType);
+                Element batchElem = UtilXml.addChildElementNSElement(entryElem, "batch:operation", feedDocument, googleBaseBatchUrl);
+                Element batchOperationElem = UtilXml.firstChildElement(batchElem, "batch:operation");
+                batchOperationElem.setAttribute("type", itemActionType);
+                
+                Element appControlElem = UtilXml.addChildElementNSElement(entryElem, "app:control", feedDocument, googleBaseAppUrl);
+                Element appControlChildElem = UtilXml.firstChildElement(appControlElem, "app:control");
+                // Add the publishing priority for the product. By default it takes about 24 hours to publish your product if you submit data from Data Feed. By adding publishing priority your data
+                // can be published in 15 - 30 minutes.
+                UtilXml.addChildElementNSValue(appControlChildElem, "gm:publishing_priority", "high", feedDocument, googleBaseMetadataUrl);
 
                 // status is draft or deactivate
                 if (statusId != null && ("draft".equals(statusId) || "deactivate".equals(statusId))) {
-                    Element appControlElem = UtilXml.addChildElement(entryElem, "app:control", feedDocument);
-                    UtilXml.addChildElementValue(appControlElem, "app:draft", "yes", feedDocument);
+                    UtilXml.addChildElementNSValue(appControlElem, "app:draft", "yes", feedDocument, googleBaseAppUrl);
 
                     // status is deactivate
                     if ("deactivate".equals(statusId)) {
-                        UtilXml.addChildElement(appControlElem, "gm:disapproved", feedDocument);
+                        UtilXml.addChildElementNSElement(appControlElem, "gm:disapproved", feedDocument, googleBaseMetadataUrl);
                     }
                 }
 
@@ -426,43 +429,64 @@
                 contentElem.setAttribute("type", "xhtml");
 
                 if (UtilValidate.isNotEmpty(googleProductId)) {
-                    UtilXml.addChildElementValue(entryElem, "id", googleProductId, feedDocument);
+                    UtilXml.addChildElementNSValue(entryElem, "g:id", googleProductId, feedDocument, googleBaseNSUrl);
                 } else {
-                    UtilXml.addChildElementValue(entryElem, "id", link, feedDocument);
+                    UtilXml.addChildElementNSValue(entryElem, "g:id", link, feedDocument, googleBaseNSUrl);
                 }
 
                 Element linkElem = UtilXml.addChildElement(entryElem, "link", feedDocument);
                 linkElem.setAttribute("rel", "alternate");
                 linkElem.setAttribute("type", "text/html");
                 linkElem.setAttribute("href", link);
-
-                UtilXml.addChildElementValue(entryElem, "g:item_type", "products", feedDocument);
-                UtilXml.addChildElementValue(entryElem, "g:price", price, feedDocument);
+                
+                // item_type is the categories in which your product should belong.
+                UtilXml.addChildElementNSValue(entryElem, "g:item_type", "products", feedDocument, googleBaseNSUrl);
+                
+                List<GenericValue> productCategoryMembers = delegator.findList("ProductCategoryMember", EntityCondition.makeCondition("productId", EntityOperator.EQUALS, prod.getString("productId")), null, UtilMisc.toList("productCategoryId"), null, false);
+                
+                Iterator productCategoryMembersIter = productCategoryMembers.iterator();
+                while (productCategoryMembersIter.hasNext()) {
+                    GenericValue productCategoryMember = (GenericValue) productCategoryMembersIter.next();
+                    GenericValue productCategory = productCategoryMember.getRelatedOne("ProductCategory");
+                    String categoryDescription = "";
+                    if (UtilValidate.isNotEmpty(productCategory.getString("categoryName"))) {
+                        categoryDescription = productCategory.getString("categoryName");  
+                    } else if (UtilValidate.isNotEmpty(productCategory.getString("description"))) {
+                        categoryDescription = productCategory.getString("description");
+                    } else if (UtilValidate.isNotEmpty(productCategory.getString("longDescription"))) {
+                        categoryDescription = productCategory.getString("longDescription");
+                    }
+                    if (UtilValidate.isNotEmpty(productCategory)) {
+                        UtilXml.addChildElementNSValue(entryElem, "g:product_type", StringUtil.wrapString(categoryDescription).toString() , feedDocument, googleBaseNSUrl);
+                    }
+                }
+                
+                UtilXml.addChildElementNSValue(entryElem, "g:price", price, feedDocument, googleBaseNSUrl);
 
                 // Might be nicer to load this from the product but for now we'll set it based on the country destination
-                UtilXml.addChildElementValue(entryElem, "g:currency", productCurrency, feedDocument);
+                UtilXml.addChildElementNSValue(entryElem, "g:currency", productCurrency, feedDocument, googleBaseNSUrl);
 
                 // Ensure the load goes to the correct country location either US dollar, GB sterling or DE euro
-                UtilXml.addChildElementValue(entryElem, "g:target_country", countryCode, feedDocument);
-
-                UtilXml.addChildElementValue(entryElem, "g:brand", prod.getString("brandName"), feedDocument);
-
+                UtilXml.addChildElementNSValue(entryElem, "g:target_country", countryCode, feedDocument, googleBaseNSUrl);
+                if (UtilValidate.isNotEmpty(prod.getString("brandName"))) {
+                    UtilXml.addChildElementNSValue(entryElem, "g:brand", prod.getString("brandName"), feedDocument, googleBaseNSUrl);
+                }
                 try {
                     googleProduct = delegator.findByPrimaryKey("GoodIdentification", UtilMisc.toMap("productId", prod.getString("productId"), "goodIdentificationTypeId", "SKU"));
                     if (UtilValidate.isNotEmpty(googleProduct)) {
-                        UtilXml.addChildElementValue(entryElem, "g:ean", googleProduct.getString("idValue"), feedDocument);
+                        UtilXml.addChildElementNSValue(entryElem, "g:ean", googleProduct.getString("idValue"), feedDocument, googleBaseNSUrl);
                     }
                 } catch (GenericEntityException gee) {
                     Debug.logInfo("Unable to get the SKU for product [" + prod.getString("productId") + "]: " + gee.getMessage(), module);
                 }
 
-                UtilXml.addChildElementValue(entryElem, "g:condition", "new", feedDocument);
+                UtilXml.addChildElementNSValue(entryElem, "g:condition", "new", feedDocument, googleBaseNSUrl);
                 // This is a US specific requirement for product feeds
                 //                     UtilXml.addChildElementValue(entryElem, "g:mpn", "", feedDocument);
 
                 // if the product has an image it will be published on Google Product Search
                 if (UtilValidate.isNotEmpty(imageLink)) {
-                    UtilXml.addChildElementValue(entryElem, "g:image_link", imageLink, feedDocument);
+                    UtilXml.addChildElementNSValue(entryElem, "g:image_link", imageLink, feedDocument, googleBaseNSUrl);
                 }
                 // if the product is exported to google for the first time, we add it to the list
                 if ("insert".equals(itemActionType)) {
@@ -477,7 +501,7 @@
                 }
                 index++;
             }
-
+            //Debug.logInfo("The value of generated String is ======== " + UtilXml.writeXmlDocument(feedDocument), module);
             dataItemsXml.append(UtilXml.writeXmlDocument(feedDocument));
         } catch (IOException e) {
             return ServiceUtil.returnError("IO Error creating XML document for Google :" + e.getMessage());
@@ -485,7 +509,6 @@
             return ServiceUtil.returnError("Unable to read from product entity: "  + e.toString());
         }
 
-
         Map result = ServiceUtil.returnSuccess();
         result.put("newProductsInGoogle", newProductsInGoogle);
         result.put("productsRemovedFromGoogle", productsRemovedFromGoogle);
@@ -566,4 +589,33 @@
         }
         return ServiceUtil.returnSuccess();
     }
+    
+    private static Map<String, Object> buildGoogleBaseConfig(Map<String, Object> context, GenericDelegator delegator) {
+        String productStoreId = (String) context.get("productStoreId");
+        Map<String, Object> buildGoogleBaseConfigContext = FastMap.newInstance();
+        
+        if (UtilValidate.isNotEmpty(productStoreId)) {
+            GenericValue googleBaseConfig = null;
+            try {
+                googleBaseConfig = delegator.findOne("GoogleBaseConfig", false, UtilMisc.toMap("productStoreId", productStoreId));
+            } catch (GenericEntityException e) {
+                Debug.logError("Unable to find value for GoogleBaseConfig", module);
+                e.printStackTrace();
+            }
+            if (UtilValidate.isNotEmpty(googleBaseConfig)) {
+               buildGoogleBaseConfigContext.put("developerKey", googleBaseConfig.getString("developerKey"));
+               buildGoogleBaseConfigContext.put("authenticationUrl", googleBaseConfig.getString("authenticationUrl"));
+               buildGoogleBaseConfigContext.put("accountEmail", googleBaseConfig.getString("accountEmail"));
+               buildGoogleBaseConfigContext.put("accountPassword", googleBaseConfig.getString("accountPassword"));
+               buildGoogleBaseConfigContext.put("postItemsUrl", googleBaseConfig.getString("postItemsUrl"));
+            }
+        } else {
+            buildGoogleBaseConfigContext.put("developerKey", UtilProperties.getPropertyValue(configString, "googleBaseExport.developerKey"));
+            buildGoogleBaseConfigContext.put("authenticationUrl", UtilProperties.getPropertyValue(configString, "googleBaseExport.authenticationUrl"));
+            buildGoogleBaseConfigContext.put("accountEmail", UtilProperties.getPropertyValue(configString, "googleBaseExport.accountEmail"));
+            buildGoogleBaseConfigContext.put("accountPassword", UtilProperties.getPropertyValue(configString, "googleBaseExport.accountPassword"));
+            buildGoogleBaseConfigContext.put("postItemsUrl", UtilProperties.getPropertyValue(configString, "googleBaseExport.postItemsUrl"));
+        }
+        return buildGoogleBaseConfigContext;
+    }    
 }
\ No newline at end of file

Modified: ofbiz/branches/executioncontext20090812/specialpurpose/googlebase/webapp/googlebase/WEB-INF/controller.xml
URL: http://svn.apache.org/viewvc/ofbiz/branches/executioncontext20090812/specialpurpose/googlebase/webapp/googlebase/WEB-INF/controller.xml?rev=810248&r1=810247&r2=810248&view=diff
==============================================================================
--- ofbiz/branches/executioncontext20090812/specialpurpose/googlebase/webapp/googlebase/WEB-INF/controller.xml (original)
+++ ofbiz/branches/executioncontext20090812/specialpurpose/googlebase/webapp/googlebase/WEB-INF/controller.xml Tue Sep  1 21:33:41 2009
@@ -47,6 +47,30 @@
         <response name="success" type="view" value="ProductsExportToGoogle"/>
         <response name="error" type="view" value="ProductsExportToGoogle"/>
     </request-map>
+    
+    <!-- Request entries for GoogleBaseConfig UI -->
+    <request-map uri="EditGoogleBaseConfigs">
+        <security https="true" auth="true"/>
+        <response name="success" type="view" value="EditGoogleBaseConfigs"/>
+    </request-map>
+    <request-map uri="createGoogleBaseConfig">
+        <security https="true" auth="true"/>
+        <event type="service" invoke="createGoogleBaseConfig"/>
+        <response name="success" type="view" value="EditGoogleBaseConfigs"/>
+        <response name="error" type="view" value="EditGoogleBaseConfigs"/>
+    </request-map>
+    <request-map uri="updateGoogleBaseConfig">
+        <security https="true" auth="true"/>
+        <event type="service" invoke="updateGoogleBaseConfig"/>
+        <response name="success" type="view" value="EditGoogleBaseConfigs"/>
+        <response name="error" type="view" value="EditGoogleBaseConfigs"/>
+    </request-map>
+    <request-map uri="deleteGoogleBaseConfig">
+        <security https="true" auth="true"/>
+        <event type="service" invoke="deleteGoogleBaseConfig"/>
+        <response name="success" type="view" value="EditGoogleBaseConfigs"/>
+        <response name="error" type="view" value="EditGoogleBaseConfigs"/>
+    </request-map>
 
     <!-- end of request mappings -->
 
@@ -56,5 +80,6 @@
     <view-map name="keywordsearch" type="screen" page="component://googlebase/widget/GoogleBaseScreens.xml#keywordsearch"/>
     <view-map name="EditProduct" type="screen" page="component://googlebase/widget/GoogleBaseScreens.xml#EditProduct"/>
     <view-map name="ProductsExportToGoogle" type="screen" page="component://googlebase/widget/GoogleBaseScreens.xml#ProductsExportToGoogle"/>
+    <view-map name="EditGoogleBaseConfigs" type="screen" page="component://googlebase/widget/GoogleBaseScreens.xml#EditGoogleBaseConfigs"/>
     <!-- end of view mappings -->
 </site-conf>

Modified: ofbiz/branches/executioncontext20090812/specialpurpose/googlebase/webapp/googlebase/WEB-INF/web.xml
URL: http://svn.apache.org/viewvc/ofbiz/branches/executioncontext20090812/specialpurpose/googlebase/webapp/googlebase/WEB-INF/web.xml?rev=810248&r1=810247&r2=810248&view=diff
==============================================================================
--- ofbiz/branches/executioncontext20090812/specialpurpose/googlebase/webapp/googlebase/WEB-INF/web.xml (original)
+++ ofbiz/branches/executioncontext20090812/specialpurpose/googlebase/webapp/googlebase/WEB-INF/web.xml Tue Sep  1 21:33:41 2009
@@ -40,7 +40,7 @@
     </context-param>
     <context-param>
         <param-name>mainDecoratorLocation</param-name>
-        <param-value>component://googlebase/widget/GoogleBaseScreens.xml</param-value>
+        <param-value>component://googlebase/widget/CommonScreens.xml</param-value>
         <description>The location of the main-decorator screen to use for this webapp; referred to as a context variable in screen def XML files.</description>
     </context-param>
 

Modified: ofbiz/branches/executioncontext20090812/specialpurpose/googlebase/widget/GoogleBaseForms.xml
URL: http://svn.apache.org/viewvc/ofbiz/branches/executioncontext20090812/specialpurpose/googlebase/widget/GoogleBaseForms.xml?rev=810248&r1=810247&r2=810248&view=diff
==============================================================================
--- ofbiz/branches/executioncontext20090812/specialpurpose/googlebase/widget/GoogleBaseForms.xml (original)
+++ ofbiz/branches/executioncontext20090812/specialpurpose/googlebase/widget/GoogleBaseForms.xml Tue Sep  1 21:33:41 2009
@@ -22,6 +22,7 @@
         xsi:noNamespaceSchemaLocation="http://ofbiz.apache.org/dtds/widget-form.xsd">
     <form name="ProductsExportToGoogle" type="single" target="searchExportProductListToGoogle"
         header-row-style="header-row" default-table-style="basic-table">
+        <field name="productStoreId"><hidden/></field>
         <field name="selectResult"><hidden/></field>
         <field name="countryCode" tooltip="${uiLabelMap.GoogleBaseExportCountryCode}">
             <drop-down no-current-selected-key="US">
@@ -31,7 +32,7 @@
                 <option key="IT" description="${uiLabelMap.GoogleBaseExportCountryCodeIT}"/>
             </drop-down>
         </field>
-        <field name="webSiteUrl"><text size="50" maxlength="250"/></field>
+        <field name="webSiteUrl"><text size="50" maxlength="250" default-value="${webSiteUrl}"/></field>
         <field name="webSiteMountPoint"><text size="30" maxlength="30" default-value="ecommerce"/></field>
         <field name="actionType">
             <drop-down no-current-selected-key="insert">
@@ -65,4 +66,37 @@
         </field>
         <field name="submitButton" title="${uiLabelMap.GoogleBaseExportToGoogle}"><submit button-type="button"/></field>
     </form>
+    
+    <form name="ListGoogleBaseConfigs" type="list"  list-name="googleBaseConfigs"  target="updateGoogleBaseConfig"
+        odd-row-style="alternate-row" header-row-style="header-row-2" default-table-style="basic-table hover-bar">
+        <actions>
+            <entity-condition entity-name="GoogleBaseConfig">
+                <order-by field-name="productStoreId"/>
+            </entity-condition>
+        </actions>
+        <auto-fields-service service-name="updateGoogleBaseConfig"/>
+        <field name="productStoreId"><display/></field>
+        <field name="deleteGoogleBaseConfig" title="" widget-style="buttontext">
+            <hyperlink target="deleteGoogleBaseConfig" description="${uiLabelMap.CommonDelete}" also-hidden="false">
+                <parameter param-name="productStoreId"/>
+            </hyperlink>
+        </field>
+        <field name="accountPassword"><password/></field>
+        <field name="submitButton" title="${uiLabelMap.CommonUpdate}"><submit button-type="button"/></field>
+    </form>
+    
+    <form name="AddGoogleBaseConfig" type="single" target="createGoogleBaseConfig" title="">
+        <auto-fields-service service-name="createGoogleBaseConfig"/>
+        <field name="productStoreId">
+            <drop-down allow-empty="false">
+                <option key="" description="- ${uiLabelMap.CommonSelectAny} -"/>
+                <entity-options entity-name="ProductStore" description="${storeName} [${productStoreId}]">
+                    <entity-order-by field-name="storeName"/>
+                </entity-options>
+            </drop-down>
+        </field>
+        <field name="accountPassword"><password/></field>
+        <field name="submitButton" title="${uiLabelMap.CommonAdd}"><submit button-type="button"/></field>
+    </form>
+    
 </forms>
\ No newline at end of file

Modified: ofbiz/branches/executioncontext20090812/specialpurpose/googlebase/widget/GoogleBaseMenus.xml
URL: http://svn.apache.org/viewvc/ofbiz/branches/executioncontext20090812/specialpurpose/googlebase/widget/GoogleBaseMenus.xml?rev=810248&r1=810247&r2=810248&view=diff
==============================================================================
--- ofbiz/branches/executioncontext20090812/specialpurpose/googlebase/widget/GoogleBaseMenus.xml (original)
+++ ofbiz/branches/executioncontext20090812/specialpurpose/googlebase/widget/GoogleBaseMenus.xml Tue Sep  1 21:33:41 2009
@@ -19,6 +19,7 @@
 -->
 <menus xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://ofbiz.apache.org/dtds/widget-menu.xsd">
     <menu name="GoogleBaseAppBar" title="${uiLabelMap.GoogleBaseApplication}" extends="CommonAppBarMenu" extends-resource="component://common/widget/CommonMenus.xml">
+        <menu-item name="GoogleBaseConfigs" title="${uiLabelMap.GoogleBaseConfiguration}"><link target="EditGoogleBaseConfigs"/></menu-item>
         <menu-item name="googlebase" title="${uiLabelMap.GoogleBaseExportToGoogle}"><link target="advancedsearch"/></menu-item>
     </menu>
 </menus>

Modified: ofbiz/branches/executioncontext20090812/specialpurpose/googlebase/widget/GoogleBaseScreens.xml
URL: http://svn.apache.org/viewvc/ofbiz/branches/executioncontext20090812/specialpurpose/googlebase/widget/GoogleBaseScreens.xml?rev=810248&r1=810247&r2=810248&view=diff
==============================================================================
--- ofbiz/branches/executioncontext20090812/specialpurpose/googlebase/widget/GoogleBaseScreens.xml (original)
+++ ofbiz/branches/executioncontext20090812/specialpurpose/googlebase/widget/GoogleBaseScreens.xml Tue Sep  1 21:33:41 2009
@@ -21,109 +21,6 @@
 <screens xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
         xsi:noNamespaceSchemaLocation="http://ofbiz.apache.org/dtds/widget-screen.xsd">
 
-    <screen name="main-decorator">
-        <section>
-            <actions>
-                <property-map resource="GoogleBaseUiLabels" map-name="uiLabelMap" global="true"/>
-                <property-map resource="ProductUiLabels" map-name="uiLabelMap" global="true"/>
-                <property-map resource="CommonUiLabels" map-name="uiLabelMap" global="true"/>
-                <property-map resource="WorkEffortUiLabels" map-name="uiLabelMap" global="true"/>
-                <set field="activeApp" value="googlebase" global="true"/>
-
-                <set field="layoutSettings.companyName" from-field="uiLabelMap.GoogleBaseCompanyName" global="true"/>
-                <set field="layoutSettings.companySubtitle" from-field="uiLabelMap.GoogleBaseApplication" global="true"/>
-                <set field="applicationMenuName" value="GoogleBaseAppBar" global="true"/>
-                <set field="applicationMenuLocation" value="component://googlebase/widget/GoogleBaseMenus.xml" global="true"/>
-                <set field="applicationTitle" value="${uiLabelMap.GoogleBaseApplication}" global="true"/>
-            </actions>
-            <widgets>
-                <include-screen name="ApplicationDecorator" location="component://commonext/widget/CommonScreens.xml"/>
-            </widgets>
-        </section>
-    </screen>
-
-    <screen name="CommonFindDecorator">
-        <section>
-            <actions>
-                <set field="headerItem" value="googlebase"/>
-            </actions>
-            <widgets>
-                <decorator-screen name="main-decorator" location="${parameters.mainDecoratorLocation}">
-                    <decorator-section name="body">
-                        <section>
-                            <condition>
-                                <if-has-permission permission="GOOGLEBASE" action="_VIEW"/>
-                            </condition>
-                            <widgets>
-                                <decorator-section-include name="body"/>
-                            </widgets>
-                            <fail-widgets>
-                                <label style="h3">${uiLabelMap.GoogleBaseViewPermissionError}</label>
-                            </fail-widgets>
-                        </section>
-                    </decorator-section>
-                </decorator-screen>
-            </widgets>
-        </section>
-    </screen>
-
-    <screen name="CommonProductDecorator">
-        <section>
-            <actions>
-                <property-map resource="PartyUiLabels" map-name="uiLabelMap" global="true"/>
-
-                <set field="productId" from-field="parameters.productId"/>
-                <entity-one entity-name="Product" value-field="product"/>
-                <set field="productName" from-field="product.productName"/>
-            </actions>
-            <widgets>
-                <decorator-screen name="main-decorator" location="${parameters.mainDecoratorLocation}">
-                    <decorator-section name="body">
-                        <section>
-                            <!-- do check for GOOGLEBASE, _VIEW permission -->
-                            <condition>
-                                <if-has-permission permission="GOOGLEBASE" action="_VIEW"/>
-                            </condition>
-                            <widgets>
-                                <section>
-                                    <condition><not><if-empty field="product"/></not></condition>
-                                    <widgets>
-                                        <include-menu name="ProductTabBar" location="component://product/widget/catalog/Menus.xml"/>
-                                        <platform-specific>
-                                            <html><html-template location="component://product/webapp/catalog/product/ProductTabBar.ftl"/></html>
-                                        </platform-specific>
-                                        <container>
-                                            <label style="h1">${uiLabelMap.${labelTitleProperty}} ${uiLabelMap.CommonFor}: ${product.internalName} [${uiLabelMap.CommonId}:${productId}]  ${${extraFunctionName}}</label>
-                                            <image src="${product.smallImageUrl}" height="40" width="40" url-mode="content"/>
-                                        </container>
-
-                                        <!-- add Create Product and View Product (in ecommerce) links -->
-                                        <container style="button-bar">
-                                            <link target="EditProduct" text="${uiLabelMap.ProductNewProduct}" style="buttontext"/>
-                                            <link target="CreateVirtualWithVariantsForm" text="${uiLabelMap.ProductNewVirtualProduct}" style="buttontext"/>
-                                            <link target="/ecommerce/control/product" url-mode="inter-app" text="${uiLabelMap.ProductProductPage}" style="buttontext">
-                                                <parameter param-name="product_id" from-field="productId"/>
-                                            </link>
-                                            <link target="ProductBarCode.pdf" target-window="_blank" text="${uiLabelMap.ProductBarcode}" style="buttontext">
-                                                <parameter param-name="productId"/>
-                                                <parameter param-name="productName"/>
-                                            </link>
-                                        </container>
-                                    </widgets>
-                                </section>
-
-                                <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="advancedsearch">
         <section>
             <actions>
@@ -138,7 +35,7 @@
                 <script location="component://product/webapp/catalog/WEB-INF/actions/find/advancedsearchoptions.groovy"/>
             </actions>
             <widgets>
-                <decorator-screen name="CommonFindDecorator">
+                <decorator-screen name="CommonFindDecorator" location="${parameters.mainDecoratorLocation}">
                     <decorator-section name="body">
                         <platform-specific>
                             <html><html-template location="component://product/webapp/catalog/find/advancedsearch.ftl"/></html>
@@ -156,7 +53,7 @@
                 <script location="component://product/webapp/catalog/WEB-INF/actions/find/keywordsearch.groovy"/>
             </actions>
             <widgets>
-                <decorator-screen name="CommonFindDecorator">
+                <decorator-screen name="CommonFindDecorator" location="${parameters.mainDecoratorLocation}">
                     <decorator-section name="body">
                         <platform-specific>
                             <html><html-template location="component://product/webapp/catalog/find/keywordsearch.ftl"/></html>
@@ -175,6 +72,7 @@
             <actions>
                 <set field="headerItem" value="googlebase"/>
                 <set field="titleProperty" value="PageTitleGoogleBaseProductsExportToGoogle"/>
+                <script location="component://googlebase/webapp/googlebase/WEB-INF/actions/productsExportToGoogle.groovy"/>
             </actions>
             <widgets>
                 <decorator-screen name="main-decorator" location="${parameters.mainDecoratorLocation}">
@@ -241,4 +139,24 @@
             </widgets>
         </section>
     </screen>
+
+    <screen name="EditGoogleBaseConfigs">
+        <section>
+            <actions>
+                <set field="titleProperty" value="GoogleBaseConfiguration"/>
+                <set field="headerItem" value="GoogleBaseConfigs"/>
+                <set field="productStoreId" from-field="parameters.productStoreId"/>
+            </actions>
+            <widgets>
+                <decorator-screen name="main-decorator" location="${parameters.mainDecoratorLocation}">
+                    <decorator-section name="body">
+                        <include-form name="ListGoogleBaseConfigs" location="component://googlebase/widget/GoogleBaseForms.xml"/>
+                        <screenlet id="add-gbs-configuration" title="${uiLabelMap.GoogleBaseAddGoogleBaseConfiguration}" collapsible="true">
+                            <include-form name="AddGoogleBaseConfig" location="component://googlebase/widget/GoogleBaseForms.xml"/>
+                        </screenlet>    
+                    </decorator-section>
+                </decorator-screen>
+            </widgets>
+        </section>
+    </screen>
 </screens>
\ No newline at end of file

Modified: ofbiz/branches/executioncontext20090812/specialpurpose/myportal/data/MyPortalTypeData.xml
URL: http://svn.apache.org/viewvc/ofbiz/branches/executioncontext20090812/specialpurpose/myportal/data/MyPortalTypeData.xml?rev=810248&r1=810247&r2=810248&view=diff
==============================================================================
--- ofbiz/branches/executioncontext20090812/specialpurpose/myportal/data/MyPortalTypeData.xml (original)
+++ ofbiz/branches/executioncontext20090812/specialpurpose/myportal/data/MyPortalTypeData.xml Tue Sep  1 21:33:41 2009
@@ -160,25 +160,7 @@
     <WebSite webSiteId="MYPORTAL" siteName="My Portal" visualThemeSetId="BACKOFFICE"/>
     
     <!-- Myportal help pages -->
-    <DataResource dataResourceId="HELP_MYPORTAL" localeString="en" dataResourceTypeId="ELECTRONIC_TEXT" dataTemplateTypeId="NONE" statusId="CTNT_IN_PROGRESS" dataResourceName="Calendar help file" mimeTypeId="text/xml" isPublic="Y" />
-    <ElectronicText dataResourceId="HELP_MYPORTAL">
-        <textData><![CDATA[
-            <root>
-                <generalTitle>
-                    The My portal Component introduction.
-                </generalTitle>
-                <general>
-                    <section>
-                        <text>
-                            Within the 'my portal' component it is possible to create a collection of screens for a specific type of user of the system.
-                            Examples are a general employee, an account manager, a customer, a supplier etc...
-                            The system makes use of special portlets which can be arranged and selected/hidden by the logged on user.
-                        </text>
-                    </section>
-                </general>
-            </root>
-        ]]></textData>
-    </ElectronicText>
+    <DataResource dataResourceId="HELP_MYPORTAL" localeString="en" dataResourceTypeId="OFBIZ_FILE" objectInfo="specialpurpose/myportal/data/helpdata/HELP_MYPORTAL.xml" dataTemplateTypeId="NONE" statusId="CTNT_IN_PROGRESS" dataResourceName="Calendar help file" mimeTypeId="text/xml" isPublic="Y" />
     <Content contentId="HELP_MYPORTAL" contentTypeId="DOCUMENT" templateDataResourceId="HELP_TEMPL" dataResourceId="HELP_MYPORTAL" statusId="CTNT_IN_PROGRESS" contentName="My Portal help" mimeTypeId="text/html"/>
     <ContentAssoc contentId="HELP_ROOT" contentIdTo="HELP_MYPORTAL" contentAssocTypeId="TREE_CHILD" fromDate="2006-01-12 01:01:01"/>
 

Modified: ofbiz/branches/executioncontext20090812/specialpurpose/oagis/widget/forms/MessageInfoForms.xml
URL: http://svn.apache.org/viewvc/ofbiz/branches/executioncontext20090812/specialpurpose/oagis/widget/forms/MessageInfoForms.xml?rev=810248&r1=810247&r2=810248&view=diff
==============================================================================
--- ofbiz/branches/executioncontext20090812/specialpurpose/oagis/widget/forms/MessageInfoForms.xml (original)
+++ ofbiz/branches/executioncontext20090812/specialpurpose/oagis/widget/forms/MessageInfoForms.xml Tue Sep  1 21:33:41 2009
@@ -27,6 +27,8 @@
             <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="viewIndex" from-field="viewIndex"/>
+                <field-map field-name="viewSize" from-field="viewSize"/>
             </service>
         </actions>
         <auto-fields-entity entity-name="OagisMessageInfo" default-field-type="display"/>
@@ -65,6 +67,8 @@
             <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="viewIndex" from-field="viewIndex"/>
+                <field-map field-name="viewSize" from-field="viewSize"/>
             </service>
         </actions>
         <auto-fields-entity entity-name="OagisMessageErrorInfo" default-field-type="display"/>

Modified: ofbiz/branches/executioncontext20090812/specialpurpose/projectmgr/widget/forms/CustRequestForms.xml
URL: http://svn.apache.org/viewvc/ofbiz/branches/executioncontext20090812/specialpurpose/projectmgr/widget/forms/CustRequestForms.xml?rev=810248&r1=810247&r2=810248&view=diff
==============================================================================
--- ofbiz/branches/executioncontext20090812/specialpurpose/projectmgr/widget/forms/CustRequestForms.xml (original)
+++ ofbiz/branches/executioncontext20090812/specialpurpose/projectmgr/widget/forms/CustRequestForms.xml Tue Sep  1 21:33:41 2009
@@ -144,6 +144,8 @@
                 <field-map field-name="inputFields" from-field="parameters"/>
                 <field-map field-name="entityName" value="WorkEffortCustRequestView"/>
                 <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>
         <row-actions>

Modified: ofbiz/branches/executioncontext20090812/specialpurpose/projectmgr/widget/forms/ProjectForms.xml
URL: http://svn.apache.org/viewvc/ofbiz/branches/executioncontext20090812/specialpurpose/projectmgr/widget/forms/ProjectForms.xml?rev=810248&r1=810247&r2=810248&view=diff
==============================================================================
--- ofbiz/branches/executioncontext20090812/specialpurpose/projectmgr/widget/forms/ProjectForms.xml (original)
+++ ofbiz/branches/executioncontext20090812/specialpurpose/projectmgr/widget/forms/ProjectForms.xml Tue Sep  1 21:33:41 2009
@@ -150,6 +150,8 @@
                 <field-map field-name="entityName" value="WorkEffortAndPartyAssign"/>
                 <field-map field-name="distinct" value="Y"/>
                 <field-map field-name="orderBy" value="-lastStatusUpdate"/>
+                <field-map field-name="viewIndex" from-field="viewIndex"/>
+                <field-map field-name="viewSize" from-field="viewSize"/>          
             </service>
         </actions>
         <row-actions>
@@ -828,6 +830,9 @@
                 <parameter param-name="fromDate"/>
             </hyperlink>
         </field>
+        <field name="downloadLink" title="${uiLabelMap.CommonEmptyHeader}" widget-style="buttontext">
+            <hyperlink description="${uiLabelMap.ContentDownload}" target="ViewSimpleContent?contentId=${contentId}"/>
+        </field>
         <field name="deleteLink" title="${uiLabelMap.CommonEmptyHeader}" widget-style="buttontext" use-when="headerItem.equals(&quot;EditTaskContents&quot;)">
             <hyperlink also-hidden="false" description="${uiLabelMap.CommonDelete}" target="deleteTaskContent">
                 <parameter param-name="contentId"/>

Modified: ofbiz/branches/executioncontext20090812/specialpurpose/projectmgr/widget/forms/TaskForms.xml
URL: http://svn.apache.org/viewvc/ofbiz/branches/executioncontext20090812/specialpurpose/projectmgr/widget/forms/TaskForms.xml?rev=810248&r1=810247&r2=810248&view=diff
==============================================================================
--- ofbiz/branches/executioncontext20090812/specialpurpose/projectmgr/widget/forms/TaskForms.xml (original)
+++ ofbiz/branches/executioncontext20090812/specialpurpose/projectmgr/widget/forms/TaskForms.xml Tue Sep  1 21:33:41 2009
@@ -179,6 +179,8 @@
                 <field-map field-name="inputFields" from-field="parameters"/>
                 <field-map field-name="entityName" value="ProjectAndPhaseAndTaskParty"/>
                 <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>
         <row-actions>

Modified: ofbiz/branches/executioncontext20090812/specialpurpose/projectmgr/widget/forms/TimeSheetForms.xml
URL: http://svn.apache.org/viewvc/ofbiz/branches/executioncontext20090812/specialpurpose/projectmgr/widget/forms/TimeSheetForms.xml?rev=810248&r1=810247&r2=810248&view=diff
==============================================================================
--- ofbiz/branches/executioncontext20090812/specialpurpose/projectmgr/widget/forms/TimeSheetForms.xml (original)
+++ ofbiz/branches/executioncontext20090812/specialpurpose/projectmgr/widget/forms/TimeSheetForms.xml Tue Sep  1 21:33:41 2009
@@ -122,6 +122,8 @@
                 <field-map field-name="inputFields" from-field="parameters"/>
                 <field-map field-name="entityName" value="Timesheet"/>
                 <field-map field-name="orderBy" value="fromDate DESC"/>
+                <field-map field-name="viewIndex" from-field="viewIndex"/>
+                <field-map field-name="viewSize" from-field="viewSize"/>
             </service>
             <set field="complete" value="${uiLabelMap.ProjectMgrToComplete}"/>
         </actions>