You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ofbiz.apache.org by ja...@apache.org on 2007/03/30 11:04:30 UTC

svn commit: r523998 - in /ofbiz/trunk/applications/manufacturing: entitydef/entitymodel.xml src/org/ofbiz/manufacturing/mrp/ProposedOrder.java

Author: jacopoc
Date: Fri Mar 30 02:04:29 2007
New Revision: 523998

URL: http://svn.apache.org/viewvc?view=rev&rev=523998
Log:
Fix for days to ship considered by the mrp.

Modified:
    ofbiz/trunk/applications/manufacturing/entitydef/entitymodel.xml
    ofbiz/trunk/applications/manufacturing/src/org/ofbiz/manufacturing/mrp/ProposedOrder.java

Modified: ofbiz/trunk/applications/manufacturing/entitydef/entitymodel.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/manufacturing/entitydef/entitymodel.xml?view=diff&rev=523998&r1=523997&r2=523998
==============================================================================
--- ofbiz/trunk/applications/manufacturing/entitydef/entitymodel.xml (original)
+++ ofbiz/trunk/applications/manufacturing/entitydef/entitymodel.xml Fri Mar 30 02:04:29 2007
@@ -167,7 +167,7 @@
       <field name="inventoryEventPlanTypeId" type="id-ne"></field>
       <field name="eventQuantity" type="floating-point"></field>
       <field name="facilityId" type="id"></field>
-      <field name="eventName" type="name"></field>
+      <field name="eventName" type="description"></field>
       <field name="isLate" type="indicator"></field>
       <prim-key field="productId"/>
       <prim-key field="eventDate"/>

Modified: ofbiz/trunk/applications/manufacturing/src/org/ofbiz/manufacturing/mrp/ProposedOrder.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/manufacturing/src/org/ofbiz/manufacturing/mrp/ProposedOrder.java?view=diff&rev=523998&r1=523997&r2=523998
==============================================================================
--- ofbiz/trunk/applications/manufacturing/src/org/ofbiz/manufacturing/mrp/ProposedOrder.java (original)
+++ ofbiz/trunk/applications/manufacturing/src/org/ofbiz/manufacturing/mrp/ProposedOrder.java Fri Mar 30 02:04:29 2007
@@ -157,7 +157,10 @@
                         }
                         // Calculate the estimatedStartDate
                         long totalTime = ProductionRun.getEstimatedTaskTime(routingTask, quantity, dispatcher);
-                        totalTime += timeToShip;
+                        if (i == listRoutingTaskAssoc.size()) {
+                            // add the daysToShip at the end of the routing
+                            totalTime += timeToShip;
+                        }
                         startDate = TechDataServices.addBackward(TechDataServices.getTechDataCalendar(routingTask),endDate, totalTime);
                         // record the routingTask with the startDate associated
                         result.put(routingTask.getString("workEffortId"),startDate);