BF - error when completing Cost collector:
Action Invalid value - -- - Reference_ID=302 - Z - C - F - V - W - X - T - R - P - D - M - B The filed right is DocAction vs Action
This commit is contained in:
parent
64dc903ce0
commit
482cf51c57
|
@ -526,11 +526,11 @@ public class MPPCostCollector extends X_PP_Cost_Collector implements DocAction
|
||||||
setDocAction(MPPOrderNode.DOCACTION_Close);
|
setDocAction(MPPOrderNode.DOCACTION_Close);
|
||||||
setDocStatus(MPPOrderNode.DOCSTATUS_Completed);
|
setDocStatus(MPPOrderNode.DOCSTATUS_Completed);
|
||||||
activity.setDocStatus(MPPOrderNode.DOCSTATUS_Completed);
|
activity.setDocStatus(MPPOrderNode.DOCSTATUS_Completed);
|
||||||
activity.setAction(MPPOrderNode.DOCACTION_None);
|
activity.setDocAction(MPPOrderNode.DOCACTION_None);
|
||||||
activity.saveEx();
|
activity.saveEx();
|
||||||
m_processMsg = Msg.translate(getCtx(), "PP_Order_ID")
|
m_processMsg = Msg.translate(getCtx(), "PP_Order_ID")
|
||||||
+": "+ getPP_Order().getDocumentNo()
|
+": "+ getPP_Order().getDocumentNo()
|
||||||
+Msg.translate(getCtx(),"PP_Order_Node_ID")
|
+" "+ Msg.translate(getCtx(),"PP_Order_Node_ID")
|
||||||
+": "+getPP_Order_Node().getValue();
|
+": "+getPP_Order_Node().getValue();
|
||||||
return DocStatus;
|
return DocStatus;
|
||||||
}
|
}
|
||||||
|
@ -859,13 +859,14 @@ public class MPPCostCollector extends X_PP_Cost_Collector implements DocAction
|
||||||
.setParameters(new Object[]{activity.get_ID(), true})
|
.setParameters(new Object[]{activity.get_ID(), true})
|
||||||
.setOnlyActiveRecords(true)
|
.setOnlyActiveRecords(true)
|
||||||
.list();
|
.list();
|
||||||
|
|
||||||
for (MPPOrderNodeProduct subcontract : subcontracts)
|
for (MPPOrderNodeProduct subcontract : subcontracts)
|
||||||
{
|
{
|
||||||
//
|
//
|
||||||
// If Product is not Purchased or is not Service, then it is not a subcontracting candidate [SKIP]
|
// If Product is not Purchased or is not Service, then it is not a subcontracting candidate [SKIP]
|
||||||
MProduct product = MProduct.get(getCtx(), subcontract.getM_Product_ID());
|
MProduct product = MProduct.get(getCtx(), subcontract.getM_Product_ID());
|
||||||
if(!product.isPurchased() || !MProduct.PRODUCTTYPE_Service.equals(product.getProductType()))
|
if(!product.isPurchased() || !MProduct.PRODUCTTYPE_Service.equals(product.getProductType()))
|
||||||
continue;
|
throw new AdempiereException("The Product: " + product.getName() + " Do not is Purchase or Service Type");
|
||||||
|
|
||||||
//
|
//
|
||||||
// Find Vendor and Product PO data
|
// Find Vendor and Product PO data
|
||||||
|
|
Loading…
Reference in New Issue