Commit 4978b39b authored by ssalve's avatar ssalve

Sarita: Done changes to set mfg_date and exp_date exists in stock against...

Sarita: Done changes to set mfg_date and exp_date exists in stock against item_code,lot_no , lot_sl on 03 SEP 2018

git-svn-id: http://15.206.35.175/svn/proteus/business-java/trunk@190252 ce508802-f39f-4f6c-b175-0d175dae99d5
parent 88f82c9d
...@@ -2454,8 +2454,11 @@ public class AdjReceiptIC extends ValidatorEJB implements AdjReceiptICRemote,Adj ...@@ -2454,8 +2454,11 @@ public class AdjReceiptIC extends ValidatorEJB implements AdjReceiptICRemote,Adj
pstmt1.setString(3,locCode); pstmt1.setString(3,locCode);
pstmt1.setString(4,lotNo); pstmt1.setString(4,lotNo);
rs1 = pstmt1.executeQuery(); rs1 = pstmt1.executeQuery();
while( rs1.next()) //commnted and changed by sarita to use if block instead while loop on 03 SEPT 2018 [START]
{ //while( rs1.next())
if(rs1.next())
{
//commnted and changed by sarita to use if block instead while loop on 03 SEPT 2018 [END]
cnt++; cnt++;
System.out.println("intered in result set hhho.."); System.out.println("intered in result set hhho..");
...@@ -2476,7 +2479,8 @@ public class AdjReceiptIC extends ValidatorEJB implements AdjReceiptICRemote,Adj ...@@ -2476,7 +2479,8 @@ public class AdjReceiptIC extends ValidatorEJB implements AdjReceiptICRemote,Adj
//mfgDate= rs1.getTimestamp("MFG_DATE"); //mfgDate= rs1.getTimestamp("MFG_DATE");
sql1="select item_ser ,unit FROM ITEM where item_code = ? "; //Commented part by sarita as the code will execute if(cnt ==0) on 03 SEPT 2018 [START]
/* sql1="select item_ser ,unit FROM ITEM where item_code = ? ";
pstmt2=conn.prepareStatement(sql1); pstmt2=conn.prepareStatement(sql1);
pstmt2.setString(1,itemCode); pstmt2.setString(1,itemCode);
rs2 = pstmt2.executeQuery(); rs2 = pstmt2.executeQuery();
...@@ -2549,7 +2553,8 @@ public class AdjReceiptIC extends ValidatorEJB implements AdjReceiptICRemote,Adj ...@@ -2549,7 +2553,8 @@ public class AdjReceiptIC extends ValidatorEJB implements AdjReceiptICRemote,Adj
valueXmlString.append("<conv__qty_stduom ><![CDATA[").append("1").append("]]></conv__qty_stduom>\r\n"); valueXmlString.append("<conv__qty_stduom ><![CDATA[").append("1").append("]]></conv__qty_stduom>\r\n");
valueXmlString.append("<unit__alt ><![CDATA[").append(unit).append("]]></unit__alt>\r\n"); valueXmlString.append("<unit__alt ><![CDATA[").append(unit).append("]]></unit__alt>\r\n");
valueXmlString.append("<potency_perc ><![CDATA[").append("0").append("]]></potency_perc>\r\n"); valueXmlString.append("<potency_perc ><![CDATA[").append("0").append("]]></potency_perc>\r\n");
stock=0; stock=0;*/
//Commented part by sarita as the code will execute if(cnt ==0) on 03 SEPT 2018 [END]
} }
rs1.close(); rs1.close();
rs1 = null; rs1 = null;
...@@ -2557,12 +2562,98 @@ public class AdjReceiptIC extends ValidatorEJB implements AdjReceiptICRemote,Adj ...@@ -2557,12 +2562,98 @@ public class AdjReceiptIC extends ValidatorEJB implements AdjReceiptICRemote,Adj
pstmt1=null; pstmt1=null;
System.out.println("cnt@@@@@@@@@1"+cnt); System.out.println("cnt@@@@@@@@@1"+cnt);
if( cnt ==0)
//Added above commented code for cnt is 0 on 03 SEP 2018 [START]
if(cnt == 0)
{
sql1="select item_ser ,unit FROM ITEM where item_code = ? ";
pstmt2=conn.prepareStatement(sql1);
pstmt2.setString(1,itemCode);
rs2 = pstmt2.executeQuery();
if( rs2.next())
{
System.out.println("intered in result set djfkvfklj hhho..");
itemSer= checkNull(rs2.getString("item_ser"));
unit= checkNull(rs2.getString("unit"));
}
rs2.close();
rs2 = null;
pstmt2.close();
pstmt2=null;
cctrCodeCr= finCommon.getAcctDetrTtype(itemCode, itemSer, "STKINVRCP", tranType, conn);
System.out.println("cctrCodeCr>>>>"+cctrCodeCr);
if(cctrCodeCr.trim().length() >0)
{
String[] arrStr =cctrCodeCr.split(",");
if(arrStr.length>0)
{
acctCodeArCr =arrStr[0];
}
if(arrStr.length>1)
{
cctrCodeArCr =arrStr[1];
}
else
{
cctrCodeArCr=" ";
}
}
accCodeInv= finCommon.getAcctDetrTtype(itemCode, itemSer, "STKINV", tranType, conn);
System.out.println("accCodeInv>>>>"+accCodeInv);
if(accCodeInv.trim().length() >0)
{
String[] arrStr =accCodeInv.split(",");
if(arrStr.length>0)
{
acctCodeAr =arrStr[0];
}
if(arrStr.length>1)
{
cctrCodeAr =arrStr[1];
}
else
{
cctrCodeAr=" ";
}
}
if(cctrCodeCr==null || cctrCodeCr.trim().length()==0)
{
cctrCodeCr="";
}
if(acctCodeCr==null || acctCodeCr.trim().length()==0)
{
acctCodeCr="";
}
valueXmlString.append("<acct_code__dr ><![CDATA[").append(acctCodeAr).append("]]></acct_code__dr>\r\n");
valueXmlString.append("<cctr_code__dr ><![CDATA[").append(cctrCodeAr).append("]]></cctr_code__dr>\r\n");
valueXmlString.append("<acct_code__cr ><![CDATA[").append(acctCodeArCr).append("]]></acct_code__cr>\r\n");
valueXmlString.append("<cctr_code__cr ><![CDATA[").append(cctrCodeArCr).append("]]></cctr_code__cr>\r\n");
//Added by sarita to store acct_code__dr and cctr_code__dr values in dom on 03 SEP 2018 [START]
setNodeValue(dom, "acct_code__dr", acctCodeAr);
setNodeValue(dom, "cctr_code__dr", cctrCodeAr);
//Added by sarita to store acct_code__dr and cctr_code__dr values in dom on 03 SEP 2018 [END]
valueXmlString.append("<conv__qty_stduom ><![CDATA[").append("1").append("]]></conv__qty_stduom>\r\n");
valueXmlString.append("<unit__alt ><![CDATA[").append(unit).append("]]></unit__alt>\r\n");
valueXmlString.append("<potency_perc ><![CDATA[").append("0").append("]]></potency_perc>\r\n");
stock=0;
}
else
//Added above commented code for cnt is 0 on 03 SEP 2018 [END]
{ {
stock = 1; stock = 1;
if(rate<=0) if(rate<=0)
{ {
valueXmlString.append("<rate ><![CDATA[").append(rate).append("]]></rate>\r\n"); valueXmlString.append("<rate ><![CDATA[").append(rate).append("]]></rate>\r\n");
//Added by sarita to set rate in dom [START]
setNodeValue( dom, "rate", String.valueOf(rate));
//Added by sarita to set rate in dom [END]
valueXmlString.append("<gross_rate ><![CDATA[").append(grossRate).append("]]></gross_rate>\r\n"); valueXmlString.append("<gross_rate ><![CDATA[").append(grossRate).append("]]></gross_rate>\r\n");
} }
...@@ -2578,24 +2669,32 @@ public class AdjReceiptIC extends ValidatorEJB implements AdjReceiptICRemote,Adj ...@@ -2578,24 +2669,32 @@ public class AdjReceiptIC extends ValidatorEJB implements AdjReceiptICRemote,Adj
valueXmlString.append("<potency_perc ><![CDATA[").append("0").append("]]></potency_perc>\r\n"); valueXmlString.append("<potency_perc ><![CDATA[").append("0").append("]]></potency_perc>\r\n");
if(mfgDate != null) if(mfgDate != null)
{ {
valueXmlString.append("<mfg_date protect='0'>").append("<![CDATA["+sdf.format(mfgDate).toString()+"]]>").append("</mfg_date>"); //valueXmlString.append("<mfg_date protect='0'>").append("<![CDATA["+sdf.format(mfgDate).toString()+"]]>").append("</mfg_date>");Conmmented and added by sarita on 03 SEP 18
valueXmlString.append("<mfg_date protect='1'>").append("<![CDATA["+sdf.format(mfgDate).toString()+"]]>").append("</mfg_date>");
}else }else
{ {
valueXmlString.append("<mfg_date protect='0'><![CDATA[").append("").append("]]></mfg_date>\r\n"); //valueXmlString.append("<mfg_date protect='0'><![CDATA[").append("").append("]]></mfg_date>\r\n");Conmmented and added by sarita on 03 SEP 18
valueXmlString.append("<mfg_date><![CDATA[").append("").append("]]></mfg_date>\r\n");
} }
if(mfgDate != null) if(mfgDate != null)
{ {
valueXmlString.append("<exp_date protect='0'>").append("<![CDATA["+sdf.format(expDate).toString()+"]]>").append("</exp_date>"); //valueXmlString.append("<exp_date protect='0'>").append("<![CDATA["+sdf.format(expDate).toString()+"]]>").append("</exp_date>");Conmmented and added by sarita on 03 SEP 18
valueXmlString.append("<exp_date protect='1'>").append("<![CDATA["+sdf.format(expDate).toString()+"]]>").append("</exp_date>");
}else }else
{ {
valueXmlString.append("<exp_date protect='0'><![CDATA[").append("").append("]]></exp_date>\r\n"); //valueXmlString.append("<exp_date protect='0'><![CDATA[").append("").append("]]></exp_date>\r\n");Conmmented and added by sarita on 03 SEP 18
valueXmlString.append("<exp_date><![CDATA[").append("").append("]]></exp_date>\r\n");
} }
valueXmlString.append("<site_code__mfg ><![CDATA[").append(siteCodeMfg).append("]]></site_code__mfg>\r\n"); valueXmlString.append("<site_code__mfg ><![CDATA[").append(siteCodeMfg).append("]]></site_code__mfg>\r\n");
if(packCode == null || packCode.trim().length()==0) if(packCode == null || packCode.trim().length()==0)
{ {
valueXmlString.append("<pack_code ><![CDATA[").append(packCode).append("]]></pack_code>\r\n"); valueXmlString.append("<pack_code ><![CDATA[").append(packCode).append("]]></pack_code>\r\n");
} }
//Added by sarita to store acct_code__dr and cctr_code__dr values in dom on 03 SEP 2018 [START]
setNodeValue(dom, "acct_code__dr", acctCodeAr);
setNodeValue(dom, "cctr_code__dr", cctrCodeAr);
//Added by sarita to store acct_code__dr and cctr_code__dr values in dom on 03 SEP 2018 [END]
} }
} }
else else
...@@ -2611,7 +2710,10 @@ public class AdjReceiptIC extends ValidatorEJB implements AdjReceiptICRemote,Adj ...@@ -2611,7 +2710,10 @@ public class AdjReceiptIC extends ValidatorEJB implements AdjReceiptICRemote,Adj
pstmt1.setString(4,lotNo); pstmt1.setString(4,lotNo);
pstmt1.setString(5,lotSl); pstmt1.setString(5,lotSl);
rs1 = pstmt1.executeQuery(); rs1 = pstmt1.executeQuery();
while( rs1.next()) //commnted and changed by sarita to use if block instead while loop on 03 SEPT 2018 [START]
//while( rs1.next())
if(rs1.next())
//commnted and changed by sarita to use if block instead while loop on 03 SEPT 2018 [END]
{ {
cnt++; cnt++;
System.out.println("intered in result set hhho.."); System.out.println("intered in result set hhho..");
...@@ -2631,8 +2733,8 @@ public class AdjReceiptIC extends ValidatorEJB implements AdjReceiptICRemote,Adj ...@@ -2631,8 +2733,8 @@ public class AdjReceiptIC extends ValidatorEJB implements AdjReceiptICRemote,Adj
siteCodeMfg= checkNull(rs1.getString("SITE_CODE__MFG")); siteCodeMfg= checkNull(rs1.getString("SITE_CODE__MFG"));
packCode= checkNull(rs1.getString("PACK_CODE")); packCode= checkNull(rs1.getString("PACK_CODE"));
//Commented part by sarita as the code will execute if(cnt ==0) on 03 SEPT 2018 [START]
sql1="SELECT ITEM_SER,UNIT FROM ITEM WHERE ITEM_CODE = ? "; /* sql1="SELECT ITEM_SER,UNIT FROM ITEM WHERE ITEM_CODE = ? ";
pstmt2=conn.prepareStatement(sql1); pstmt2=conn.prepareStatement(sql1);
pstmt2.setString(1,itemCode); pstmt2.setString(1,itemCode);
rs2 = pstmt2.executeQuery(); rs2 = pstmt2.executeQuery();
...@@ -2694,8 +2796,8 @@ public class AdjReceiptIC extends ValidatorEJB implements AdjReceiptICRemote,Adj ...@@ -2694,8 +2796,8 @@ public class AdjReceiptIC extends ValidatorEJB implements AdjReceiptICRemote,Adj
valueXmlString.append("<unit__alt ><![CDATA[").append(unit).append("]]></unit__alt>\r\n"); valueXmlString.append("<unit__alt ><![CDATA[").append(unit).append("]]></unit__alt>\r\n");
valueXmlString.append("<potency_perc ><![CDATA[").append("0").append("]]></potency_perc>\r\n"); valueXmlString.append("<potency_perc ><![CDATA[").append("0").append("]]></potency_perc>\r\n");
stock=0; stock=0;*/
//Commented part by sarita as the code will execute if(cnt ==0) on 03 SEPT 2018 [END]
} }
rs1.close(); rs1.close();
rs1 = null; rs1 = null;
...@@ -2703,12 +2805,86 @@ public class AdjReceiptIC extends ValidatorEJB implements AdjReceiptICRemote,Adj ...@@ -2703,12 +2805,86 @@ public class AdjReceiptIC extends ValidatorEJB implements AdjReceiptICRemote,Adj
pstmt1=null; pstmt1=null;
System.out.println("cnt@@@@@@@@@2"+cnt); System.out.println("cnt@@@@@@@@@2"+cnt);
if( cnt ==0) //Added above commented code for cnt is 0 on 03 SEP 2018 [START]
if( cnt == 0)
{ {
sql1="SELECT ITEM_SER,UNIT FROM ITEM WHERE ITEM_CODE = ? ";
pstmt2=conn.prepareStatement(sql1);
pstmt2.setString(1,itemCode);
rs2 = pstmt2.executeQuery();
if( rs2.next())
{
System.out.println("intered in result set djfkvfklj hhho..");
itemSer= checkNull(rs2.getString("item_ser"));
unit= checkNull(rs2.getString("unit"));
}
rs2.close();
rs2 = null;
pstmt2.close();
pstmt2=null;
cctrCodeCr= finCommon.getAcctDetrTtype(itemCode, itemSer, "STKINVRCP", tranType, conn);
System.out.println("cctrCodeCr>>>>"+cctrCodeCr);
if(cctrCodeCr.trim().length() >0)
{
String[] arrStr =cctrCodeCr.split(",");
if(arrStr.length>0)
{
acctCodeArCr =arrStr[0];
}
if(arrStr.length>1)
{
cctrCodeArCr =arrStr[1];
}
else
{
cctrCodeArCr=" ";
}
}
accCodeInv= finCommon.getAcctDetrTtype(itemCode, itemSer, "STKINV", tranType, conn);
System.out.println("cctrCodeCr>>>>"+acct);
if(accCodeInv.trim().length() >0)
{
String[] arrStr =accCodeInv.split(",");
if(arrStr.length>0)
{
acctCodeAr =arrStr[0];
}
if(arrStr.length>1)
{
cctrCodeAr =arrStr[1];
}
else
{
cctrCodeAr=" ";
}
}
valueXmlString.append("<acct_code__dr ><![CDATA[").append(acctCodeAr).append("]]></acct_code__dr>\r\n");
valueXmlString.append("<cctr_code__dr ><![CDATA[").append(cctrCodeAr).append("]]></cctr_code__dr>\r\n");
valueXmlString.append("<acct_code__cr ><![CDATA[").append(acctCodeArCr).append("]]></acct_code__cr>\r\n");
valueXmlString.append("<cctr_code__cr ><![CDATA[").append(cctrCodeArCr).append("]]></cctr_code__cr>\r\n");
valueXmlString.append("<conv__qty_stduom ><![CDATA[").append("0").append("]]></conv__qty_stduom>\r\n");
valueXmlString.append("<unit__alt ><![CDATA[").append(unit).append("]]></unit__alt>\r\n");
valueXmlString.append("<potency_perc ><![CDATA[").append("0").append("]]></potency_perc>\r\n");
stock=0;
//Added by sarita to store acct_code__dr and cctr_code__dr values in dom on 03 SEP 2018 [START]
setNodeValue(dom, "acct_code__dr", acctCodeAr);
setNodeValue(dom, "cctr_code__dr", cctrCodeAr);
//Added by sarita to store acct_code__dr and cctr_code__dr values in dom on 03 SEP 2018 [END]
}
else
{
//Added above commented code for cnt is 0 on 03 SEP 2018 [END]
stock = 1; stock = 1;
if(rate<=0) if(rate<=0)
{ {
valueXmlString.append("<rate ><![CDATA[").append(rate).append("]]></rate>\r\n"); valueXmlString.append("<rate ><![CDATA[").append(rate).append("]]></rate>\r\n");
//Added by sarita to set rate in dom [START]
setNodeValue(dom, "rate", String.valueOf(rate));
//Added by sarita to set rate in dom [START]
valueXmlString.append("<gross_rate ><![CDATA[").append(grossRate).append("]]></gross_rate>\r\n"); valueXmlString.append("<gross_rate ><![CDATA[").append(grossRate).append("]]></gross_rate>\r\n");
} }
...@@ -2723,25 +2899,33 @@ public class AdjReceiptIC extends ValidatorEJB implements AdjReceiptICRemote,Adj ...@@ -2723,25 +2899,33 @@ public class AdjReceiptIC extends ValidatorEJB implements AdjReceiptICRemote,Adj
valueXmlString.append("<unit__alt ><![CDATA[").append(unit).append("]]></unit__alt>\r\n"); valueXmlString.append("<unit__alt ><![CDATA[").append(unit).append("]]></unit__alt>\r\n");
valueXmlString.append("<potency_perc ><![CDATA[").append("0").append("]]></potency_perc>\r\n"); valueXmlString.append("<potency_perc ><![CDATA[").append("0").append("]]></potency_perc>\r\n");
if(mfgDate != null) if(mfgDate != null)
{ {
valueXmlString.append("<mfg_date protect='0'>").append("<![CDATA["+sdf.format(mfgDate).toString()+"]]>").append("</mfg_date>"); //valueXmlString.append("<mfg_date protect='0'>").append("<![CDATA["+sdf.format(mfgDate).toString()+"]]>").append("</mfg_date>"); Conmmented and added by sarita on 03 SEP 18
valueXmlString.append("<mfg_date protect='1'>").append("<![CDATA["+sdf.format(mfgDate).toString()+"]]>").append("</mfg_date>");
}else }else
{ {
valueXmlString.append("<mfg_date protect='0'><![CDATA[").append("").append("]]></mfg_date>\r\n"); //valueXmlString.append("<mfg_date protect='0'><![CDATA[").append("").append("]]></mfg_date>\r\n");Conmmented and added by sarita on 03 SEP 18
valueXmlString.append("<mfg_date><![CDATA[").append("").append("]]></mfg_date>\r\n");
} }
if(mfgDate != null) if(mfgDate != null)
{ {
valueXmlString.append("<exp_date protect='0'>").append("<![CDATA["+sdf.format(expDate).toString()+"]]>").append("</exp_date>"); //valueXmlString.append("<exp_date protect='0'>").append("<![CDATA["+sdf.format(expDate).toString()+"]]>").append("</exp_date>");Conmmented and added by sarita on 03 SEP 18
valueXmlString.append("<exp_date protect='1'>").append("<![CDATA["+sdf.format(expDate).toString()+"]]>").append("</exp_date>");
}else }else
{ {
valueXmlString.append("<exp_date protect='0'><![CDATA[").append("").append("]]></exp_date>\r\n"); //valueXmlString.append("<exp_date protect='0'><![CDATA[").append("").append("]]></exp_date>\r\n");Conmmented and added by sarita on 03 SEP 18
valueXmlString.append("<exp_date><![CDATA[").append("").append("]]></exp_date>\r\n");
} }
valueXmlString.append("<site_code__mfg ><![CDATA[").append(siteCodeMfg).append("]]></site_code__mfg>\r\n"); valueXmlString.append("<site_code__mfg ><![CDATA[").append(siteCodeMfg).append("]]></site_code__mfg>\r\n");
if(packCode == null || packCode.trim().length()==0) if(packCode == null || packCode.trim().length()==0)
{ {
valueXmlString.append("<pack_code ><![CDATA[").append(packCode).append("]]></pack_code>\r\n"); valueXmlString.append("<pack_code ><![CDATA[").append(packCode).append("]]></pack_code>\r\n");
} }
//Added by sarita to store acct_code__dr and cctr_code__dr values in dom on 03 SEP 2018 [START]
setNodeValue(dom, "acct_code__dr", acctCodeAr);
setNodeValue(dom, "cctr_code__dr", cctrCodeAr);
//Added by sarita to store acct_code__dr and cctr_code__dr values in dom on 03 SEP 2018 [END]
} }
} }
rateStr=checkNull(genericUtility.getColumnValue("rate",dom)); rateStr=checkNull(genericUtility.getColumnValue("rate",dom));
...@@ -2788,8 +2972,12 @@ public class AdjReceiptIC extends ValidatorEJB implements AdjReceiptICRemote,Adj ...@@ -2788,8 +2972,12 @@ public class AdjReceiptIC extends ValidatorEJB implements AdjReceiptICRemote,Adj
} }
if(cctrCodeAr.trim().length()> 0 && acctCodeAr.trim().length() > 0 && stock == 1) if(cctrCodeAr.trim().length()> 0 && acctCodeAr.trim().length() > 0 && stock == 1)
{ {
valueXmlString.append("<acct_code__dr protect=\"1\" ><![CDATA[").append("").append("]]></acct_code__dr>\r\n"); //commented and added by sarita to set value of acct_code__dr & cctr_code__dr if value exist on 03 SEP 2018 [START]
valueXmlString.append("<cctr_code__dr protect=\"1\" ><![CDATA[").append("").append("]]></cctr_code__dr>\r\n"); /*valueXmlString.append("<acct_code__dr protect=\"1\" ><![CDATA[").append("").append("]]></acct_code__dr>\r\n");
valueXmlString.append("<cctr_code__dr protect=\"1\" ><![CDATA[").append("").append("]]></cctr_code__dr>\r\n");*/
valueXmlString.append("<acct_code__dr protect=\"1\" ><![CDATA[").append(acctCodeAr).append("]]></acct_code__dr>\r\n");
valueXmlString.append("<cctr_code__dr protect=\"1\" ><![CDATA[").append(cctrCodeAr).append("]]></cctr_code__dr>\r\n");
//commented and added by sarita to set value of acct_code__dr & cctr_code__dr if value exist on 03 SEP 2018 [END]
} }
else if(cctrCodeAr.trim().length() == 0 && acctCodeAr.trim().length() == 0 && stock == 1) else if(cctrCodeAr.trim().length() == 0 && acctCodeAr.trim().length() == 0 && stock == 1)
...@@ -2848,14 +3036,28 @@ public class AdjReceiptIC extends ValidatorEJB implements AdjReceiptICRemote,Adj ...@@ -2848,14 +3036,28 @@ public class AdjReceiptIC extends ValidatorEJB implements AdjReceiptICRemote,Adj
valueXmlString.append("<acct_code__dr ><![CDATA[").append(acctCodeAr).append("]]></acct_code__dr>\r\n"); valueXmlString.append("<acct_code__dr ><![CDATA[").append(acctCodeAr).append("]]></acct_code__dr>\r\n");
valueXmlString.append("<cctr_code__dr ><![CDATA[").append(cctrCodeAr).append("]]></cctr_code__dr>\r\n"); valueXmlString.append("<cctr_code__dr ><![CDATA[").append(cctrCodeAr).append("]]></cctr_code__dr>\r\n");
valueXmlString.append("<acct_code__cr ><![CDATA[").append(acctCodeArCr).append("]]></acct_code__cr>\r\n"); valueXmlString.append("<acct_code__cr ><![CDATA[").append(acctCodeArCr).append("]]></acct_code__cr>\r\n");
valueXmlString.append("<cctr_code__cr ><![CDATA[").append(cctrCodeArCr).append("]]></cctr_code__cr>\r\n"); valueXmlString.append("<cctr_code__cr ><![CDATA[").append(cctrCodeArCr).append("]]></cctr_code__cr>\r\n");
} }
else else
{ {
valueXmlString.append("<acct_code__dr protect=\"0\" ><![CDATA[").append("").append("]]></acct_code__dr>\r\n"); //Commented and added by sarita to set acct_code__dr & cctr_code__dr values using dom on 03 SEP 2018 [START]
valueXmlString.append("<cctr_code__dr protect=\"0\" ><![CDATA[").append("").append("]]></cctr_code__dr>\r\n"); acctCodeAr=checkNull(genericUtility.getColumnValue("acct_code__dr",dom));
} cctrCodeAr=checkNull(genericUtility.getColumnValue("cctr_code__dr",dom));
System.out.println("acctCodeAr ["+acctCodeAr+"] \t cctrCodeAr ["+cctrCodeAr+"]");
if((acctCodeAr != null && acctCodeAr.trim().length() > 0) && (cctrCodeAr != null && cctrCodeAr.trim().length() > 0))
{
valueXmlString.append("<acct_code__dr protect=\"0\" ><![CDATA[").append(acctCodeAr).append("]]></acct_code__dr>\r\n");
valueXmlString.append("<cctr_code__dr protect=\"0\" ><![CDATA[").append(cctrCodeAr).append("]]></cctr_code__dr>\r\n");
}
else
{
valueXmlString.append("<acct_code__dr protect=\"0\" ><![CDATA[").append("").append("]]></acct_code__dr>\r\n");
valueXmlString.append("<cctr_code__dr protect=\"0\" ><![CDATA[").append("").append("]]></cctr_code__dr>\r\n");
}
//valueXmlString.append("<acct_code__dr protect=\"0\" ><![CDATA[").append("").append("]]></acct_code__dr>\r\n");
//valueXmlString.append("<cctr_code__dr protect=\"0\" ><![CDATA[").append("").append("]]></cctr_code__dr>\r\n");
//Commented and added by sarita to set acct_code__dr & cctr_code__dr values using dom on 03 SEP 2018 [END]
}
} }
catch (Exception e) catch (Exception e)
{ {
......
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