Commit 6da984a7 authored by ngadkari's avatar ngadkari

added doc_key and invoice reference in xml

git-svn-id: http://15.206.35.175/svn/proteus/business-java/trunk@206738 ce508802-f39f-4f6c-b175-0d175dae99d5
parent 00534dbf
...@@ -247,6 +247,7 @@ public class SalesReturnFormSplit extends ActionHandlerEJB implements SalesRetur ...@@ -247,6 +247,7 @@ public class SalesReturnFormSplit extends ActionHandlerEJB implements SalesRetur
java.text.SimpleDateFormat sdf = null; java.text.SimpleDateFormat sdf = null;
int lineNo = 0, crCount = 0; int lineNo = 0, crCount = 0;
String retRef="",reasCodeH = "",fullRetHdr=""; String retRef="",reasCodeH = "",fullRetHdr="";
String invoiceRef="",docKey="";// added by nandkumar gadkari on 03/09/19
try try
{ {
DistCommon distCommom = new DistCommon(); DistCommon distCommom = new DistCommon();
...@@ -403,6 +404,7 @@ public class SalesReturnFormSplit extends ActionHandlerEJB implements SalesRetur ...@@ -403,6 +404,7 @@ public class SalesReturnFormSplit extends ActionHandlerEJB implements SalesRetur
+ " conv__rtuom_stduom, unit__std, quantity__stduom, rate__stduom, exp_date, " + " conv__rtuom_stduom, unit__std, quantity__stduom, rate__stduom, exp_date, "
+ " discount, tax_amt, site_code__mfg, mfg_date, unit__rate, pack_code, full_ret, " + " discount, tax_amt, site_code__mfg, mfg_date, unit__rate, pack_code, full_ret, "
+ " item_ser, rate__clg, cost_rate,cr_term,ship_to_zip_code,claim_qty,physical_qty " + " item_ser, rate__clg, cost_rate,cr_term,ship_to_zip_code,claim_qty,physical_qty "
+ " ,invoice_ref,doc_key " // added by nandkumar gadkari on 03/09/19
+ " FROM sreturn_form_det WHERE tran_id = ? "; + " FROM sreturn_form_det WHERE tran_id = ? ";
pstmt = conn.prepareStatement(sql); pstmt = conn.prepareStatement(sql);
pstmt.setString(1, tranId); pstmt.setString(1, tranId);
...@@ -458,6 +460,8 @@ public class SalesReturnFormSplit extends ActionHandlerEJB implements SalesRetur ...@@ -458,6 +460,8 @@ public class SalesReturnFormSplit extends ActionHandlerEJB implements SalesRetur
crterm = checkNull(rs.getString("cr_term")); crterm = checkNull(rs.getString("cr_term"));
shiptozip = checkNull(rs.getString("ship_to_zip_code")); shiptozip = checkNull(rs.getString("ship_to_zip_code"));
invoiceRef = checkNull(rs.getString("invoice_ref")); // added by nandkumar gadkari on 03/09/19
docKey = checkNull(rs.getString("doc_key")); // added by nandkumar gadkari on 03/09/19
// 21/11/11 manoharan check whether to consider cr_term, ship_to_zip_code in splitcode // 21/11/11 manoharan check whether to consider cr_term, ship_to_zip_code in splitcode
if (itemSerDet == null || itemSerDet.trim().length() == 0) if (itemSerDet == null || itemSerDet.trim().length() == 0)
{ {
...@@ -687,6 +691,8 @@ public class SalesReturnFormSplit extends ActionHandlerEJB implements SalesRetur ...@@ -687,6 +691,8 @@ public class SalesReturnFormSplit extends ActionHandlerEJB implements SalesRetur
tempMap.put("rate__clg", getReqDecimal(rate, 4)); tempMap.put("rate__clg", getReqDecimal(rate, 4));
} }
tempMap.put("cost_rate", getReqDecimal(costRate, 3)); tempMap.put("cost_rate", getReqDecimal(costRate, 3));
tempMap.put("invoice_ref", invoiceRef);// added by nandkumar gadkari on 03/09/19
tempMap.put("doc_key", docKey);// added by nandkumar gadkari on 03/09/19
tempList.add(tempMap); tempList.add(tempMap);
...@@ -1230,7 +1236,20 @@ public class SalesReturnFormSplit extends ActionHandlerEJB implements SalesRetur ...@@ -1230,7 +1236,20 @@ public class SalesReturnFormSplit extends ActionHandlerEJB implements SalesRetur
{ {
xmlBuff.append("<cost_rate><![CDATA[0]]></cost_rate>"); xmlBuff.append("<cost_rate><![CDATA[0]]></cost_rate>");
} }
// added by nandkumar gadkari on 03/09/19---------start-------------
if ( tempMap.get("invoice_id") == null || (String)tempMap.get("invoice_id") == null || ((String)tempMap.get("invoice_id")).trim().length() == 0 )
{
if ( tempMap.get("invoice_ref") != null )
{
xmlBuff.append("<invoice_ref><![CDATA["+ (String)tempMap.get("invoice_ref") +"]]></invoice_ref>");
}
if ( tempMap.get("doc_key") != null )
{
xmlBuff.append("<doc_key><![CDATA["+ (String)tempMap.get("doc_key") +"]]></doc_key>");
}
}
// added by nandkumar gadkari on 03/09/19---------end-------------
//sreturn_hdr.setitem(mtot_row, "eff_net_amt", mtot_eff_amt) //sreturn_hdr.setitem(mtot_row, "eff_net_amt", mtot_eff_amt)
//sreturn_hdr.setitem(mtot_row, "tax_amt", mtot_tax_amt) //sreturn_hdr.setitem(mtot_row, "tax_amt", mtot_tax_amt)
//sreturn_hdr.setitem(mtot_row, "net_amt", mtot_net_amt) //sreturn_hdr.setitem(mtot_row, "net_amt", mtot_net_amt)
......
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