Commit 62936b5a authored by cpatil's avatar cpatil

*** empty log message ***


git-svn-id: http://15.206.35.175/svn/proteus/business-java/trunk@97721 ce508802-f39f-4f6c-b175-0d175dae99d5
parent 4c65f238
......@@ -3624,6 +3624,47 @@ public class RunMRPPrc extends ProcessEJB implements RunMRPPrcLocal, RunMRPPrcRe
if(isDetailReq)
{
System.out.println("@@@@@010415:::itemCodeAdp["+itemCodeAdp+"]demandAdp["+demandAdp+"]-supplyAdp["+supplyAdp+"]+reorderLevel["+reorderLevel+"]");
/*if((demandAdp - supplyAdp) < reorderLevel )
{
adpElement.setDemand(demandAdp-supplyAdp+reorderLevel);
}*/
if( supplyAdp == 0 && checkNull(saleOrderAdp).trim().length() > 0 )
{
//demandAdp = demandAdp + reorderLevel ;
demandAdp = reorderLevel ;
adpElement.setDemand(demandAdp);
boolean mrpFlag = false;
ArrayList <TimeMRP>timemrpList=adpElement.getTimeMrpList();
ArrayList <TimeMRP>timemrpListN=new ArrayList<TimeMRP>();
if(timemrpList.size()>0)
{
for(int k=0;k<timemrpList.size();k++)
{
TimeMRP tmp=timemrpList.get(k);
if( tmp.getDemand() > 0 && mrpFlag == false )
{
System.out.println("@@@@@010415:::itemCodeAdp["+itemCodeAdp+"] tmp.getDemand()["+tmp.getDemand()+"]-tmp.getSupply()["+tmp.getSupply()+"]+reorderLevel["+reorderLevel+"]");
tmp.setDemand( demandAdp ) ;
System.out.println("@@@@@010415:::tmp.getDemand()["+tmp.getDemand()+"]");
//tmp.setRunningDemand(reorderLevel);
tmp.setRunningDemand( demandAdp );
System.out.println("@@@@@010415:::tmp.getRunningDemand()["+tmp.getRunningDemand()+"]");
mrpFlag = true;
}
timemrpListN.add(tmp);
}
adpElement.SetTimeMRPArr(timemrpListN);
}
}
ArrayList<HashMap<String, ADPElement>> detList=adpElement.getDetList();
for(int l=0;l<detList.size();l++)
{
......@@ -4126,7 +4167,7 @@ public class RunMRPPrc extends ProcessEJB implements RunMRPPrcLocal, RunMRPPrcRe
double prevpendDRQty=0;
double qtStk=0;//added by Chandrashekar 0n 11-08-14
String siteCodeAdp="",tempitemCodeList="";
double reorderLevel=0,planSupply=0;
double reorderLevel=0,planSupply=0,netReqd=0;
try
{
......@@ -4402,7 +4443,16 @@ public class RunMRPPrc extends ProcessEJB implements RunMRPPrcLocal, RunMRPPrcRe
reorderLevel=adpElement.getReorderLevel();
if(reorderLevel>0)
{
netReqd=adpElement.getDemand()-dataBeanTemp.getSupply();
planSupply=adpElement.getDemand()-dataBeanTemp.getSupply()+reorderLevel;
System.out.println("netReqd["+netReqd+"]");
System.out.println("before deduction planSupply["+planSupply+"]");
if(netReqd>0)
{
planSupply=planSupply-netReqd;
}
System.out.println("after deduction planSupply["+planSupply+"]");
////if(planSupply<=re)
adpElement.setDemand(dueDate,planSupply, adpElement.getSaleOrder(),adpElement.getLineNo());
adpElement.setReordPlanQty(planSupply);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment