Author: jleroux
Date: Tue Aug 27 10:26:02 2013 New Revision: 1517780 URL: http://svn.apache.org/r1517780 Log: A patch from Pierre Smits for "ProudctionRunServices.xml doesn't set dateTimeManufactured in inventoryItem" https://issues.apache.org/jira/browse/OFBIZ-5299 When producing a good in Manufacturing the manufacturing date and time doesn't get set in the inventoryItem jleroux: I also noticed that 1 instance of datetimeReceived for SERIALIZED_INV_ITEM in productionRunTaskProduce used UtilDateTime.nowDate() instead UtilDateTime.nowTimestamp(), I changed it. Modified: ofbiz/trunk/applications/manufacturing/src/org/ofbiz/manufacturing/jobshopmgt/ProductionRunServices.java Modified: ofbiz/trunk/applications/manufacturing/src/org/ofbiz/manufacturing/jobshopmgt/ProductionRunServices.java URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/manufacturing/src/org/ofbiz/manufacturing/jobshopmgt/ProductionRunServices.java?rev=1517780&r1=1517779&r2=1517780&view=diff ============================================================================== --- ofbiz/trunk/applications/manufacturing/src/org/ofbiz/manufacturing/jobshopmgt/ProductionRunServices.java (original) +++ ofbiz/trunk/applications/manufacturing/src/org/ofbiz/manufacturing/jobshopmgt/ProductionRunServices.java Tue Aug 27 10:26:02 2013 @@ -1660,6 +1660,7 @@ public class ProductionRunServices { "statusId", "INV_AVAILABLE"); serviceContext.put("facilityId", productionRun.getGenericValue().getString("facilityId")); serviceContext.put("datetimeReceived", UtilDateTime.nowTimestamp()); + serviceContext.put("datetimeManufactured", UtilDateTime.nowTimestamp()); serviceContext.put("comments", "Created by production run " + productionRunId); if (unitCost.compareTo(ZERO) != 0) { serviceContext.put("unitCost", unitCost); @@ -1697,6 +1698,7 @@ public class ProductionRunServices { "inventoryItemTypeId", "NON_SERIAL_INV_ITEM"); serviceContext.put("facilityId", productionRun.getGenericValue().getString("facilityId")); serviceContext.put("datetimeReceived", UtilDateTime.nowTimestamp()); + serviceContext.put("datetimeManufactured", UtilDateTime.nowTimestamp()); serviceContext.put("comments", "Created by production run " + productionRunId); serviceContext.put("lotId", lotId); if (unitCost.compareTo(ZERO) != 0) { @@ -1854,7 +1856,8 @@ public class ProductionRunServices { "inventoryItemTypeId", "SERIALIZED_INV_ITEM", "statusId", "INV_AVAILABLE"); serviceContext.put("facilityId", facilityId); - serviceContext.put("datetimeReceived", UtilDateTime.nowDate()); + serviceContext.put("datetimeReceived", UtilDateTime.nowTimestamp()); + serviceContext.put("datetimeManufactured", UtilDateTime.nowTimestamp()); serviceContext.put("comments", "Created by production run task " + productionRunTaskId); if (unitCost != null) { serviceContext.put("unitCost", unitCost); @@ -1893,6 +1896,7 @@ public class ProductionRunServices { "inventoryItemTypeId", "NON_SERIAL_INV_ITEM"); serviceContext.put("facilityId", facilityId); serviceContext.put("datetimeReceived", UtilDateTime.nowTimestamp()); + serviceContext.put("datetimeManufactured", UtilDateTime.nowTimestamp()); serviceContext.put("comments", "Created by production run task " + productionRunTaskId); if (unitCost != null) { serviceContext.put("unitCost", unitCost); |
Free forum by Nabble | Edit this page |