Commit 9befccf6 authored by prane's avatar prane

to set lot_sl on lot_no in SRF as per same logic as SalesReturn

git-svn-id: http://15.206.35.175/svn/proteus/business-java/trunk@203969 ce508802-f39f-4f6c-b175-0d175dae99d5
parent 4cb8b9aa
......@@ -3881,6 +3881,56 @@ public class SReturnForm extends ValidatorEJB implements SReturnFormLocal, SRetu
valueXmlString.append("<discount>").append("<![CDATA[" + discount + "]]>").append("</discount>");
setNodeValue( dom, "discount", discount );
System.out.println("END getMinRate start");
//Pavan R on 24Jul19 start [to set lot_sl as per same from SalesReturn]
String lslotsl="";
System.out.println("site_code is:"+siteCode);
System.out.println("lotNo is:"+lotNo);
System.out.println("locCode is:"+locCode);
System.out.println("itemCode is:"+itemCode);
sql="select lot_sl from stock where site_code = ? and " +
"lot_no = ? and item_code = ?";
pstmt= conn.prepareStatement( sql );//,,,
pstmt.setString( 1, siteCode);
pstmt.setString( 2, lotNo );
pstmt.setString( 3, itemCode );
rs = pstmt.executeQuery();
if( rs.next() )
{
lslotsl = rs.getString(1);
}
rs.close();
pstmt.close();
pstmt = null;
rs = null;
System.out.println("*********Lot sl is:"+lslotsl);
if (lslotsl == null || lslotsl.trim().length() == 0)
{
System.out.println("lslotsl is null in lot_no itemChanged"+lslotsl);
String lsSretLotsl="";
lsSretLotsl = distCommon.getDisparams( "999999", "SRETURN_DEFAULT_LOTSL", conn );
System.out.println("lsSretLotsl ["+lsSretLotsl+"] in lot_no Disparam Value");
if(lsSretLotsl == null || lsSretLotsl.trim().length()== 0 || "NULLFOUND".equalsIgnoreCase(lsSretLotsl))
{
valueXmlString.append("<lot_sl>").append("2S").append("</lot_sl>");
setNodeValue( dom, "lot_sl","2S");
}
else
{
System.out.println("lsSretLotsl["+lsSretLotsl+"]");
valueXmlString.append("<lot_sl>").append("<![CDATA[" + lsSretLotsl + "]]>").append("</lot_sl>");
setNodeValue( dom, "lot_sl",lsSretLotsl);
}
}
else
{
valueXmlString.append("<lot_sl>").append("<![CDATA[" + lslotsl + "]]>").append("</lot_sl>");
setNodeValue( dom, "lot_sl",lslotsl);
}
//Pavan R on 24Jul19 end
//Changed by Nandkumar Gadkari on 23/10/2018 to not to set rate if already set from min_rate_history [Start]
//StringBuffer minRateBuff = getMinRate( dom, dom1, currentColumn.trim(), valueXmlString, conn );
// StringBuffer minRateBuff = null;
......@@ -3897,6 +3947,8 @@ public class SReturnForm extends ValidatorEJB implements SReturnFormLocal, SRetu
//Pavan Rane 22Jul19[to set mfg_date from item_lot_info as per same logic from salesReturn]
valueXmlString = (gbfIcExpMfgDate(valueXmlString, dom, dom1, dom2, editFlag, xtraParams, objContext,
conn));
System.out.println("lslotsl["+lslotsl+"]");
//Pavan Rane 22Jul19 end
reStr = itemChanged(dom, dom1, dom2, objContext, "lot_sl", editFlag, xtraParams);
......
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