Commit f37174ca authored by ajadhav's avatar ajadhav

If po_rate_option in item master is "N", then rate field should be non...

If po_rate_option in item master is "N", then rate field should be non editable add logic on line_no__ord

git-svn-id: http://15.206.35.175/svn/proteus/business-java/trunk@183861 ce508802-f39f-4f6c-b175-0d175dae99d5
parent a3b7a7ce
......@@ -1985,6 +1985,12 @@ public class PoReceiptIc extends ValidatorEJB implements PoReceiptIcLocal,PoRec
lspotype=rs.getString(1);
}
//Add by Ajay on 18/04/18:START
rs.close();
rs=null;
pstmt.close();
rs=null;
//END
if( "Q".equalsIgnoreCase(lspotype.trim()) || "H".equalsIgnoreCase(lspotype.trim()) )
{
......@@ -6134,13 +6140,9 @@ public class PoReceiptIc extends ValidatorEJB implements PoReceiptIcLocal,PoRec
valueXmlString.append("<lot_no protect=\"1\"><![CDATA[").append(" ").append("]]></lot_no>\r\n");
valueXmlString.append("<lot_sl protect=\"1\" ><![CDATA[").append(" ").append("]]></lot_sl>\r\n");
}
/*else
{
valueXmlString.append("<lot_no protect=\"0\"><![CDATA[").append(" ").append("]]></lot_no>\r\n");
valueXmlString.append("<lot_sl protect=\"0\" ><![CDATA[").append(" ").append("]]></lot_sl>\r\n");
}*/
//Add by Ajay on 10/04/18:END
sql="select case when po_rate_option is null then 'N' else po_rate_option end" +
......@@ -6226,6 +6228,8 @@ public class PoReceiptIc extends ValidatorEJB implements PoReceiptIcLocal,PoRec
lspurcorder= checkNull(genericUtility.getColumnValue("purc_order", dom));
lsporcpline =checkNull( genericUtility.getColumnValue("line_no", dom));
lsitemcode=checkNull(genericUtility.getColumnValue( "item_code", dom ));
String rate=(genericUtility.getColumnValue("rate", dom));
String reasCode=(genericUtility.getColumnValue("reas_code", dom));
System.out.println("LINE NUMBER IN DOM"+mPordLine);
mPordLine = " " + mPordLine;
mPordLine = mPordLine.substring(mPordLine.length() - 3,mPordLine.length());
......@@ -7147,6 +7151,34 @@ public class PoReceiptIc extends ValidatorEJB implements PoReceiptIcLocal,PoRec
valueXmlString.append("<lot_sl protect=\"0\" ><![CDATA[").append(" ").append("]]></lot_sl>\r\n");
}
//Add by Ajay on 10/04/18:END
//Add by Ajay on 19/04/18:START
sql="select case when po_rate_option is null then 'N' else po_rate_option end" +
" from item where item_code = ?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, lsitemcode);
rs = pstmt.executeQuery();
if (rs.next()) {
lsporateoption = checkNull(rs.getString(1));
}
rs.close();
rs = null;
pstmt.close();
pstmt = null;
if(lsporateoption == null || lsporateoption.trim().length() == 0)
{
lsporateoption="N";
}
if("N".equalsIgnoreCase(lsporateoption))
{
valueXmlString.append("<rate protect =\"1\">").append("<![CDATA["+rate+"]]>").append("</rate>");
}
else
{
valueXmlString.append("<rate protect =\"0\">").append("<![CDATA["+rate+"]]>").append("</rate>");
}
valueXmlString.append("<reas_code protect =\"1\">").append("<![CDATA["+reasCode+"]]>").append("</reas_code>");
//Add by Ajay on 19/04/18:END
}
......
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