Author: mridulpathak
Date: Sat May 21 12:21:20 2016
New Revision: 1744925
URL: http://svn.apache.org/viewvc?rev=1744925&view=rev
Log:
[OFBIZ-7098] RUN MRP is not working properly for multiple facilities. It
deletes the 'Proposed' requirements for all facilities and creates only for
selected facility. Thanks Ankit Joshi for reporting the issue and providing the
patch.
Modified:
ofbiz/trunk/applications/manufacturing/src/org/ofbiz/manufacturing/mrp/MrpServices.java
Modified:
ofbiz/trunk/applications/manufacturing/src/org/ofbiz/manufacturing/mrp/MrpServices.java
URL:
http://svn.apache.org/viewvc/ofbiz/trunk/applications/manufacturing/src/org/ofbiz/manufacturing/mrp/MrpServices.java?rev=1744925&r1=1744924&r2=1744925&view=diff
==============================================================================
---
ofbiz/trunk/applications/manufacturing/src/org/ofbiz/manufacturing/mrp/MrpServices.java
(original)
+++
ofbiz/trunk/applications/manufacturing/src/org/ofbiz/manufacturing/mrp/MrpServices.java
Sat May 21 12:21:20 2016
@@ -94,7 +94,7 @@ public class MrpServices {
List<GenericValue> listResultRoles = new LinkedList<GenericValue>();
try {
listResult = EntityQuery.use(delegator).from("Requirement")
- .where("requirementTypeId", "PRODUCT_REQUIREMENT",
+ .where("requirementTypeId",
"PRODUCT_REQUIREMENT","facilityId", facilityId,
"statusId", "REQ_PROPOSED")
.queryList();
} catch (GenericEntityException e) {
@@ -115,7 +115,7 @@ public class MrpServices {
listResult = null;
try {
listResult = EntityQuery.use(delegator).from("Requirement")
- .where("requirementTypeId", "INTERNAL_REQUIREMENT",
+ .where("requirementTypeId",
"INTERNAL_REQUIREMENT","facilityId", facilityId,
"statusId", "REQ_PROPOSED")
.queryList();
} catch (GenericEntityException e) {