Commit da0aa1f9 authored by mjadhav's avatar mjadhav

replace blank space for msg_spes if '|'


git-svn-id: http://15.206.35.175/svn/proteus/business-java/trunk@97261 ce508802-f39f-4f6c-b175-0d175dae99d5
parent c5b90af3
...@@ -571,7 +571,7 @@ public class GenInvoiceSchedule implements Schedule { ...@@ -571,7 +571,7 @@ public class GenInvoiceSchedule implements Schedule {
String sql=""; String sql="";
String custCode="",siteCode="",custCodeBil=""; String custCode="",siteCode="",custCodeBil="";
String siteAreaCode="",siteAdd1="",siteAdd2="",sitecity="",sitePin="",siteStateCode="",siteRegNo="",siteContactPersion=""; String siteAreaCode="",siteAdd1="",siteAdd2="",siteAdd3="",sitecity="",sitePin="",siteStateCode="",siteRegNo="",siteContactPersion="";
String custAdd1="",custAdd2="",custCity="",custState="",custPin="",custTaxreg="",custType="",custName="",custCountrtCode=""; String custAdd1="",custAdd2="",custCity="",custState="",custPin="",custTaxreg="",custType="",custName="",custCountrtCode="";
String rate="",unitRate="",discountInv="",siteDescr="",custCodeBill="",custCodeDlv=""; String rate="",unitRate="",discountInv="",siteDescr="",custCodeBill="",custCodeDlv="";
String dlvAdd1="",dlvAdd2="",dlvCity="",dlvPin="",dlvCountryCode="",siteStatedescr="",custStatedescr="",custNameBill="",custNameDlv=""; String dlvAdd1="",dlvAdd2="",dlvCity="",dlvPin="",dlvCountryCode="",siteStatedescr="",custStatedescr="",custNameBill="",custNameDlv="";
...@@ -643,7 +643,7 @@ public class GenInvoiceSchedule implements Schedule { ...@@ -643,7 +643,7 @@ public class GenInvoiceSchedule implements Schedule {
sql = "select AREA_CODE,ADD1,ADD2,CITY,PIN,STATE_CODE,CONTACT_PERSON,DESCR,FIN_ENTITY from site where SITE_CODE =?" ; sql = "select AREA_CODE,ADD1,ADD2,ADD3,CITY,PIN,STATE_CODE,CONTACT_PERSON,DESCR,FIN_ENTITY from site where SITE_CODE =?" ;
pstmt = conn.prepareStatement(sql); pstmt = conn.prepareStatement(sql);
pstmt.setString(1, siteCode); pstmt.setString(1, siteCode);
...@@ -653,6 +653,7 @@ public class GenInvoiceSchedule implements Schedule { ...@@ -653,6 +653,7 @@ public class GenInvoiceSchedule implements Schedule {
siteAreaCode=rs.getString("AREA_CODE"); siteAreaCode=rs.getString("AREA_CODE");
siteAdd1=rs.getString("ADD1"); siteAdd1=rs.getString("ADD1");
siteAdd2=rs.getString("ADD2"); siteAdd2=rs.getString("ADD2");
siteAdd3=rs.getString("ADD3");
sitecity=rs.getString("CITY"); sitecity=rs.getString("CITY");
sitePin=rs.getString("PIN"); sitePin=rs.getString("PIN");
siteStateCode=rs.getString("STATE_CODE"); siteStateCode=rs.getString("STATE_CODE");
...@@ -964,6 +965,7 @@ public class GenInvoiceSchedule implements Schedule { ...@@ -964,6 +965,7 @@ public class GenInvoiceSchedule implements Schedule {
siteAreaCode = siteAreaCode == null ? " " : siteAreaCode.trim(); siteAreaCode = siteAreaCode == null ? " " : siteAreaCode.trim();
siteAdd1 = siteAdd1 == null ? " " : siteAdd1.trim(); siteAdd1 = siteAdd1 == null ? " " : siteAdd1.trim();
siteAdd2 = siteAdd2 == null ? " " : siteAdd2.trim(); siteAdd2 = siteAdd2 == null ? " " : siteAdd2.trim();
siteAdd3 = siteAdd3 == null ? " " : siteAdd3.trim();
sitecity = sitecity == null ? " " : sitecity.trim(); sitecity = sitecity == null ? " " : sitecity.trim();
sitePin = sitePin == null ? " " : sitePin.trim(); sitePin = sitePin == null ? " " : sitePin.trim();
siteStateCode = siteStateCode == null ? " " : siteStateCode.trim(); siteStateCode = siteStateCode == null ? " " : siteStateCode.trim();
...@@ -1017,7 +1019,7 @@ public class GenInvoiceSchedule implements Schedule { ...@@ -1017,7 +1019,7 @@ public class GenInvoiceSchedule implements Schedule {
/*------------------------------------------------------------------------------------------------*/ /*------------------------------------------------------------------------------------------------*/
Element addressInSpain = doc.createElement("AddressInSpain"); Element addressInSpain = doc.createElement("AddressInSpain");
addressInSpain.appendChild(getElementValue(doc, parties, "Address", siteAdd1)); addressInSpain.appendChild(getElementValue(doc, parties, "Address", siteAdd1+" "+siteAdd2 +" "+siteAdd3));
addressInSpain.appendChild(getElementValue(doc, parties, "PostCode", sitePin)); addressInSpain.appendChild(getElementValue(doc, parties, "PostCode", sitePin));
addressInSpain.appendChild(getElementValue(doc, parties, "Town", sitecity)); addressInSpain.appendChild(getElementValue(doc, parties, "Town", sitecity));
addressInSpain.appendChild(getElementValue(doc, parties, "Province", siteStatedescr)); addressInSpain.appendChild(getElementValue(doc, parties, "Province", siteStatedescr));
...@@ -1047,7 +1049,7 @@ public class GenInvoiceSchedule implements Schedule { ...@@ -1047,7 +1049,7 @@ public class GenInvoiceSchedule implements Schedule {
admCustDlv.appendChild(getElementValue(doc, parties, "Name", nameReg1)); admCustDlv.appendChild(getElementValue(doc, parties, "Name", nameReg1));
} }
Element addCustDlv = doc.createElement("AddressInSpain"); Element addCustDlv = doc.createElement("AddressInSpain");
addCustDlv.appendChild(getElementValue(doc, parties, "Address", add1Reg1)); addCustDlv.appendChild(getElementValue(doc, parties, "Address", add1Reg1 + " "+add2Reg1 + " "+add3Reg1));
addCustDlv.appendChild(getElementValue(doc, parties, "PostCode", pinReg1)); addCustDlv.appendChild(getElementValue(doc, parties, "PostCode", pinReg1));
addCustDlv.appendChild(getElementValue(doc, parties, "Town", cityReg1)); addCustDlv.appendChild(getElementValue(doc, parties, "Town", cityReg1));
addCustDlv.appendChild(getElementValue(doc, parties, "Province", stateDescrReg1)); addCustDlv.appendChild(getElementValue(doc, parties, "Province", stateDescrReg1));
...@@ -1069,7 +1071,7 @@ public class GenInvoiceSchedule implements Schedule { ...@@ -1069,7 +1071,7 @@ public class GenInvoiceSchedule implements Schedule {
admCustBill.appendChild(getElementValue(doc, parties, "Name", nameReg2)); admCustBill.appendChild(getElementValue(doc, parties, "Name", nameReg2));
} }
Element addCustBill = doc.createElement("AddressInSpain"); Element addCustBill = doc.createElement("AddressInSpain");
addCustBill.appendChild(getElementValue(doc, parties, "Address", add1Reg2)); addCustBill.appendChild(getElementValue(doc, parties, "Address", add1Reg2 + " " + add2Reg2 + " "+add3Reg2));
addCustBill.appendChild(getElementValue(doc, parties, "PostCode", pinReg2)); addCustBill.appendChild(getElementValue(doc, parties, "PostCode", pinReg2));
addCustBill.appendChild(getElementValue(doc, parties, "Town", cityReg2)); addCustBill.appendChild(getElementValue(doc, parties, "Town", cityReg2));
addCustBill.appendChild(getElementValue(doc, parties, "Province", stateDescrReg2)); addCustBill.appendChild(getElementValue(doc, parties, "Province", stateDescrReg2));
...@@ -1089,7 +1091,7 @@ public class GenInvoiceSchedule implements Schedule { ...@@ -1089,7 +1091,7 @@ public class GenInvoiceSchedule implements Schedule {
administrativeCentres.appendChild(getElementValue(doc, parties, "Name", nameReg3)); administrativeCentres.appendChild(getElementValue(doc, parties, "Name", nameReg3));
} }
Element addressbuyer = doc.createElement("AddressInSpain"); Element addressbuyer = doc.createElement("AddressInSpain");
addressbuyer.appendChild(getElementValue(doc, parties, "Address", add1Reg3)); addressbuyer.appendChild(getElementValue(doc, parties, "Address", add1Reg3 + " "+add2Reg3 + " "+add3Reg3));
addressbuyer.appendChild(getElementValue(doc, parties, "PostCode", pinReg3)); addressbuyer.appendChild(getElementValue(doc, parties, "PostCode", pinReg3));
addressbuyer.appendChild(getElementValue(doc, parties, "Town", cityReg3)); addressbuyer.appendChild(getElementValue(doc, parties, "Town", cityReg3));
addressbuyer.appendChild(getElementValue(doc, parties, "Province", stateDescrReg3)); addressbuyer.appendChild(getElementValue(doc, parties, "Province", stateDescrReg3));
...@@ -1111,7 +1113,7 @@ public class GenInvoiceSchedule implements Schedule { ...@@ -1111,7 +1113,7 @@ public class GenInvoiceSchedule implements Schedule {
addlegalEntity.appendChild(getElementValue(doc, parties, "PostCode", sitePin)); addlegalEntity.appendChild(getElementValue(doc, parties, "PostCode", sitePin));
addlegalEntity.appendChild(getElementValue(doc, parties, "Town", sitecity)); addlegalEntity.appendChild(getElementValue(doc, parties, "Town", sitecity));
addlegalEntity.appendChild(getElementValue(doc, parties, "Province", siteStatedescr));*/ addlegalEntity.appendChild(getElementValue(doc, parties, "Province", siteStatedescr));*/
addlegalEntity.appendChild(getElementValue(doc, parties, "Address",custBillAdd2)); addlegalEntity.appendChild(getElementValue(doc, parties, "Address",custBillAdd1+" "+custBillAdd2+" "+custBillAdd3));
addlegalEntity.appendChild(getElementValue(doc, parties, "PostCode", custBillPin)); addlegalEntity.appendChild(getElementValue(doc, parties, "PostCode", custBillPin));
addlegalEntity.appendChild(getElementValue(doc, parties, "Town", custBillCity)); addlegalEntity.appendChild(getElementValue(doc, parties, "Town", custBillCity));
addlegalEntity.appendChild(getElementValue(doc, parties, "Province", custBillStatedescr)); addlegalEntity.appendChild(getElementValue(doc, parties, "Province", custBillStatedescr));
...@@ -1283,7 +1285,7 @@ public class GenInvoiceSchedule implements Schedule { ...@@ -1283,7 +1285,7 @@ public class GenInvoiceSchedule implements Schedule {
" where ci.cust_code=i.cust_code__bil " + " where ci.cust_code=i.cust_code__bil " +
" and idet.item_code = ci.item_code and idet.item_code = ? and i.cust_code__bil= ? ";*/ " and idet.item_code = ci.item_code and idet.item_code = ? and i.cust_code__bil= ? ";*/
sql = "select MSG_SPECS from CUSTOMERITEM ci,customer c , item i where " + sql = "select replace(MSG_SPECS,'|',' ' ) from CUSTOMERITEM ci,customer c , item i where " +
" c.cust_code = ci.cust_code and i.item_code = ci.item_code " + " c.cust_code = ci.cust_code and i.item_code = ci.item_code " +
" and ci.item_code=? and ci.cust_code=? " ; " and ci.item_code=? and ci.cust_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