Commit 5620161c authored by kshinde's avatar kshinde

D18CKOY001 Changes in sales return form to split on basis of invoice ID

git-svn-id: http://15.206.35.175/svn/proteus/business-java/trunk@186639 ce508802-f39f-4f6c-b175-0d175dae99d5
parent 848651c6
......@@ -235,7 +235,7 @@ public class SalesReturnFormSplit extends ActionHandlerEJB implements SalesRetur
String custCd = "";
String custCodeBill="",custCodeDlv="",siteCodeDlv = "";
double lineNoInv = 0, quantity = 0, netAmountDet = 0, rate = 0, effNetAmountDet = 0,claimQuantity = 0,physicalQuantity=0;
double lineNoInv = 0, quantity = 0, netAmountDet = 0, rate = 0, effNetAmountDet = 0,claimQuantity = 0,physicalQuantity=0,lineNoInvtrace=0;
double convQtyStdUom = 0, convRtUomStdUom = 0, quantityStdUom = 0, rateStdUom = 0;
double discount = 0, taxAmtDet = 0, rateClg = 0, costRate = 0;
......@@ -347,7 +347,7 @@ public class SalesReturnFormSplit extends ActionHandlerEJB implements SalesRetur
projCode = checkNull(rs.getString("proj_code"));
analCode = checkNull(rs.getString("anal_code"));
remarks = checkNull(rs.getString("remarks"));
//fullRet = checkNull(rs.getString("full_ret"));
fullRet = checkNull(rs.getString("full_ret"));
//currCode = checkNull(rs.getString("curr_code"));
currCode = rs.getString("curr_code");
exchRate = rs.getDouble("exch_rate");
......@@ -397,7 +397,7 @@ public class SalesReturnFormSplit extends ActionHandlerEJB implements SalesRetur
rs = null;
// end 21/11/11 manoharan check whether to consider cr_term, ship_to_zip_code in splitcode
sql =" SELECT line_no, invoice_id, line_no__inv, item_code, quantity, net_amt, "
sql =" SELECT line_no, invoice_id, line_no__inv,line_no__invtrace,item_code, quantity, net_amt, "
+ " status, reas_code, loc_code, stk_opt, rate, lot_no, lot_sl, tax_class, "
+ " tax_chap, tax_env, unit, ret_rep_flag, eff_net_amt, conv__qty_stduom, "
+ " conv__rtuom_stduom, unit__std, quantity__stduom, rate__stduom, exp_date, "
......@@ -413,6 +413,7 @@ public class SalesReturnFormSplit extends ActionHandlerEJB implements SalesRetur
{
invoiceIdDet = checkNull(rs.getString("invoice_id"));
lineNoInv = rs.getDouble("line_no__inv");
lineNoInvtrace = rs.getDouble("line_no__invtrace");
itemCode = checkNull(rs.getString("item_code"));
quantity = rs.getDouble("quantity");
claimQuantity = rs.getDouble("claim_qty");
......@@ -448,11 +449,12 @@ public class SalesReturnFormSplit extends ActionHandlerEJB implements SalesRetur
//mfgDate = rs.getDate("mfg_date");
//unitRate = checkNull(rs.getString("unit__rate"));
packCode = checkNull(rs.getString("pack_code"));
//fullRet = checkNull(rs.getString("full_ret"));
fullRet = checkNull(rs.getString("full_ret"));
itemSerDet = checkNull(rs.getString("item_ser"));
rateClg = rs.getDouble("rate__clg");
costRate = rs.getDouble("cost_rate");
crterm = checkNull(rs.getString("cr_term"));
shiptozip = checkNull(rs.getString("ship_to_zip_code"));
// 21/11/11 manoharan check whether to consider cr_term, ship_to_zip_code in splitcode
......@@ -574,11 +576,11 @@ public class SalesReturnFormSplit extends ActionHandlerEJB implements SalesRetur
// 21/11/11 manoharan check whether to consider cr_term, ship_to_zip_code in splitcode
if (crCount > 0 )
{
tempSplitCode = itemSerDet+"@"+crterm+"@"+custCd; // **************** this need to be changed as per taro requirement
tempSplitCode = itemSerDet+"@"+crterm+"@"+custCd+"@"+invoiceIdDet+"@"+statusDet; // **************** this need to be changed as per taro requirement
}
else
{
tempSplitCode = itemSerDet;
tempSplitCode = itemSerDet+"@"+invoiceIdDet+"@"+statusDet;
}
// end 21/11/11 manoharan check whether to consider cr_term, ship_to_zip_code in splitcode
if(splitCodeWiseMap.containsKey(tempSplitCode))
......@@ -597,6 +599,7 @@ public class SalesReturnFormSplit extends ActionHandlerEJB implements SalesRetur
tempMap.put("invoice_id", invoiceIdDet);
tempMap.put("line_no__inv", ("" + lineNoInv));
tempMap.put("line_no__invtrace", ("" + lineNoInvtrace));
tempMap.put("item_code", itemCode);
tempMap.put("quantity", getReqDecimal(quantity, 3));
......@@ -666,10 +669,10 @@ public class SalesReturnFormSplit extends ActionHandlerEJB implements SalesRetur
tempMap.put("unit__rate", unitRate);
tempMap.put("pack_code", packCode);
//tempMap.put("full_ret", fullRet);
tempMap.put("full_ret", "Y");
tempMap.put("full_ret", fullRet);
/*tempMap.put("full_ret", "Y");
System.out.println("Full ret = Y");
tempMap.put("item_ser", itemSerDet);
*/tempMap.put("item_ser", itemSerDet);
if(rateClg != 0)
{
tempMap.put("rate__clg", getReqDecimal(rateClg, 4));
......@@ -936,6 +939,14 @@ public class SalesReturnFormSplit extends ActionHandlerEJB implements SalesRetur
{
xmlBuff.append("<line_no__inv/>");
}
if ( tempMap.get("line_no__invtrace") != null )
{
xmlBuff.append("<line_no__invtrace>" + (String)tempMap.get("line_no__invtrace") + "</line_no__invtrace>");
}
else
{
xmlBuff.append("<line_no__invtrace/>");
}
if ( tempMap.get("item_code") != null )
{
xmlBuff.append("<item_code>" + (String)tempMap.get("item_code") + "</item_code>");
......
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