svn commit: r1758997 - in /ofbiz/trunk/applications/product/groovyScripts/facility/inventory: InventoryAverageCosts.groovy InventoryItemTotals.groovy

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

svn commit: r1758997 - in /ofbiz/trunk/applications/product/groovyScripts/facility/inventory: InventoryAverageCosts.groovy InventoryItemTotals.groovy

Deepak Dixit-5
Author: deepak
Date: Fri Sep  2 17:44:55 2016
New Revision: 1758997

URL: http://svn.apache.org/viewvc?rev=1758997&view=rev
Log:
(OFBIZ-7390) Applied slightly patch from jira issue:
================================
Print PDF functionality throws exception on Inventory Average Cost screen
================================
Thanks Avnindra Sharma for your contribution.

Modified:
    ofbiz/trunk/applications/product/groovyScripts/facility/inventory/InventoryAverageCosts.groovy
    ofbiz/trunk/applications/product/groovyScripts/facility/inventory/InventoryItemTotals.groovy

Modified: ofbiz/trunk/applications/product/groovyScripts/facility/inventory/InventoryAverageCosts.groovy
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/product/groovyScripts/facility/inventory/InventoryAverageCosts.groovy?rev=1758997&r1=1758996&r2=1758997&view=diff
==============================================================================
--- ofbiz/trunk/applications/product/groovyScripts/facility/inventory/InventoryAverageCosts.groovy (original)
+++ ofbiz/trunk/applications/product/groovyScripts/facility/inventory/InventoryAverageCosts.groovy Fri Sep  2 17:44:55 2016
@@ -25,6 +25,7 @@ import org.apache.ofbiz.entity.condition
 import org.apache.ofbiz.entity.util.EntityUtil;
 
 facilityId = context.get("facilityId");
+searchParameterString = "action=Y&facilityId=" + facilityId;
 
 EntityCondition whereConditions = EntityCondition.makeCondition("facilityId", EntityOperator.EQUALS, facilityId);
 inventoryItems = select("productId").from("InventoryItem").where("facilityId", facilityId).orderBy("productId").queryList();
@@ -47,4 +48,5 @@ inventoryItemProducts.each { productId -
     }
 }
 
+context.searchParameterString = searchParameterString;
 context.inventoryAverageCosts = inventoryAverageCosts;

Modified: ofbiz/trunk/applications/product/groovyScripts/facility/inventory/InventoryItemTotals.groovy
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/product/groovyScripts/facility/inventory/InventoryItemTotals.groovy?rev=1758997&r1=1758996&r2=1758997&view=diff
==============================================================================
--- ofbiz/trunk/applications/product/groovyScripts/facility/inventory/InventoryItemTotals.groovy (original)
+++ ofbiz/trunk/applications/product/groovyScripts/facility/inventory/InventoryItemTotals.groovy Fri Sep  2 17:44:55 2016
@@ -31,6 +31,7 @@ retailPriceGrandTotal = 0.0;
 totalCostPriceGrandTotal = 0.0;
 totalRetailPriceGrandTotal = 0.0;
 boolean beganTransaction = false;
+searchParameterString = "action=Y&facilityId=" + facilityId;
 if (action) {
     conditions = [EntityCondition.makeCondition("statusId", EntityOperator.NOT_EQUAL, "INV_DELIVERED")];
     conditions.add(EntityCondition.makeCondition("statusId", EntityOperator.EQUALS, null));
@@ -106,5 +107,6 @@ inventoryItemGrandTotals = [];
 inventoryItemGrandTotals.add([qohGrandTotal : qohGrandTotal, atpGrandTotal : atpGrandTotal,
                               totalCostPriceGrandTotal : totalCostPriceGrandTotal, totalRetailPriceGrandTotal : totalRetailPriceGrandTotal]);
 
+context.searchParameterString = searchParameterString;
 context.inventoryItemTotals = inventoryItemTotals;
 context.inventoryItemGrandTotals = inventoryItemGrandTotals;