org.adempiere.pipo2.exception.POSaveFailedException: Failed to save column Movement Quantity
if( bom != null
&& !MPPProductBOM.BOMTYPE_Make_To_Order.equals(bom.getBOMType())
&& !MPPProductBOM.BOMTYPE_Make_To_Kit.equals(bom.getBOMType()) )
{
throw new AdempiereException("@NotFound@ @PP_ProductBOM_ID@");
}
Hi Red1,
Thanks for your feedback, as I know that manufacturing module must support 2
types of manufacturing order.
First, manufacturing order created to fulfill the stock and achieve level of
availability ( called Make To Stock or MTS), requirement can be taken from
monthly demand or forecasting.
Second, manufacturing order created base on order(called Make To Order or MTO).
In Libero, I see MTO scenario is supported but not MTS.
So I try MTS scenario by using bom type "Current Active" because "Make-To-Stock" or "Make-To-Kit" is already designed to support MTO scenario only.
I change MMPMRP.java at line 127 becomes
//Validate BOM
if(bom == null && pp != null)
{
bom = new MPPProductBOM(ol.getCtx(), pp.getPP_Product_BOM_ID(), ol.get_TrxName());
if( bom != null
&& !MPPProductBOM.BOMTYPE_Make_To_Order.equals(bom.getBOMType())
&& !MPPProductBOM.BOMTYPE_Make_To_Kit.equals(bom.getBOMType()) )
{
/*FERRY 12.12.2015
* If BOM Type is current active not need to create MO
*/
if ( MPPProductBOM.BOMTYPE_CurrentActive.equals(bom.getBOMType()) )
{
return null;
}
else
{
throw new AdempiereException("@NotFound@ @PP_ProductBOM_ID@");
}
}
}
I test it and so far it works. I can create sales order well, the it created "DEMAND" on MRP View, then I run Calculate Material Plan and system creates draft of manufacturing order base on totally demand(check on screenshot).
Demand Qty: 5 + 4 + 3 + 250 = 262
On Hand Qty: 160
New Manufacturing Order = 262 - 160 = 102 , because on my setting a manufacturing order must be multiplied by 24 (1 lot = 24) then system proposes 144 ( 6 x @24)
Thanks,
Ferry Irawan