Commit 558af9df authored by vkadam's avatar vkadam

Changes after review


git-svn-id: http://15.206.35.175/svn/proteus/business-java/trunk@96706 ce508802-f39f-4f6c-b175-0d175dae99d5
parent 9b81c6bf
/********************************************************
Title : BillofQuantityIC
Date : 20/09/12
Developer: Akhilesh Sikarwar
Title : Customer
Date : 20/10/14
Developer: Vallabh Kadam
********************************************************/
package ibase.webitm.ejb.dis;
......@@ -29,44 +29,44 @@ import org.w3c.dom.NodeList;
@Stateless
public class Customer extends ValidatorEJB
implements CustomerLocal, CustomerRemote {
implements CustomerLocal, CustomerRemote
{
GenericUtility genericUtility = GenericUtility.getInstance();
String winName = null;
FinCommon finCommon = null;
ValidatorEJB validator = null;
public String wfValData(String xmlString, String xmlString1,
String xmlString2, String objContext, String editFlag,
String xtraParams) throws RemoteException, ITMException {
public String wfValData(String xmlString, String xmlString1, String xmlString2, String objContext, String editFlag, String xtraParams) throws RemoteException, ITMException
{
String errString = "";
Document dom = null;
Document dom1 = null;
Document dom2 = null;
try {
System.out.println("Val xmlString :: " + xmlString);
System.out.println("Val xmlString1 :: " + xmlString1);
System.out.println("Val xmlString2 :: " + xmlString2);
if (xmlString != null && xmlString.trim().length() > 0) {
try
{
if (xmlString != null && xmlString.trim().length() > 0)
{
dom = parseString(xmlString);
}
if (xmlString1 != null && xmlString1.trim().length() > 0) {
if (xmlString1 != null && xmlString1.trim().length() > 0)
{
dom1 = parseString(xmlString1);
}
if (xmlString2 != null && xmlString2.trim().length() > 0) {
if (xmlString2 != null && xmlString2.trim().length() > 0)
{
dom2 = parseString("<Root>" + xmlString2 + "</Root>");
}
errString = wfValData(dom, dom1, dom2, objContext, editFlag,
xtraParams);
} catch (Exception e) {
errString = wfValData(dom, dom1, dom2, objContext, editFlag, xtraParams);
} catch (Exception e)
{
e.printStackTrace();
throw new ITMException(e);
}
return errString;
}
public String wfValData(Document dom, Document dom1, Document dom2,
String objContext, String editFlag, String xtraParams)
throws RemoteException, ITMException {
public String wfValData(Document dom, Document dom1, Document dom2, String objContext, String editFlag, String xtraParams) throws RemoteException, ITMException
{
NodeList parentNodeList = null;
NodeList childNodeList = null;
Node parentNode = null;
......@@ -79,58 +79,59 @@ implements CustomerLocal, CustomerRemote {
String errorType = "";
String errString = "";
String tranId = "";
String custCode="",ignoreCredit="",ignoreDays="",acctCodeAdv="",cctrCodeAdv="",groupCode="",custCodeBil="",stanCode="",terrCode="";
String stateCode="",countCode="",crTerm="",currCode="",currCode1="",acctCodeAr="",cctrCodeAr="",taxClass="",taxChap="",priceList="";
String salesPers="",tranCode="",siteCodeRcp="",siteCode="",channelPartner="",blackListing="",contactCode="",bankCode="",priceListDisc="";
String salesOption="",dlvTerm="",lossPerc="",adhocReplPerc="",termTableNo="",priceListClg="",salesPers1="",salesPers2="";
String keyFlag="",active="",lsVal3="",empCodeOrd="",empCodeOrd1="",custCodePd="",custCodeDisc="",sgroupCode="",custCodeAr="",currCodeFrt="";
String blankVar="",custName="",shName="",availableYn="",creditLmt="",round="",roundTo="",currCodeIns="";
String regCode="",validUpto="",regDate="";
String custCode = "", ignoreCredit = "", ignoreDays = "", acctCodeAdv = "", cctrCodeAdv = "", groupCode = "", custCodeBil = "", stanCode = "", terrCode = "";
String stateCode = "", countCode = "", crTerm = "", currCode = "", currCode1 = "", acctCodeAr = "", cctrCodeAr = "", taxClass = "", taxChap = "", priceList = "";
String salesPers = "", tranCode = "", siteCodeRcp = "", siteCode = "", channelPartner = "", blackListing = "", contactCode = "", bankCode = "", priceListDisc = "";
String salesOption = "", dlvTerm = "", lossPerc = "", adhocReplPerc = "", termTableNo = "", priceListClg = "", salesPers1 = "", salesPers2 = "";
String keyFlag = "", active = "", lsVal3 = "", empCodeOrd = "", empCodeOrd1 = "", custCodePd = "", custCodeDisc = "", sgroupCode = "", custCodeAr = "", currCodeFrt = "";
String blankVar = "", custName = "", shName = "", availableYn = "", creditLmt = "", round = "", roundTo = "", currCodeIns = "";
String regCode = "", validUpto = "", regDate = "";
int ctr = 0;
int currentFormNo = 0;
int cnt = 0,cnt1=0;
int cnt = 0, cnt1 = 0;
ArrayList errList = new ArrayList();
ArrayList errFields = new ArrayList();
Connection conn = null;
PreparedStatement pstmt = null;
ResultSet rs = null;
ConnDriver connDriver = new ConnDriver();
StringBuffer errStringXml = new StringBuffer(
"<?xml version = \"1.0\"?> \r\n <Root> <Errors>");
try {
StringBuffer errStringXml = new StringBuffer("<?xml version = \"1.0\"?> \r\n <Root> <Errors>");
try
{
this.finCommon = new FinCommon();
this.validator = new ValidatorEJB();
conn = connDriver.getConnectDB("DriverITM");
userId = getValueFromXTRA_PARAMS(xtraParams, "loginCode");
if ((objContext != null) && (objContext.trim().length() > 0)) {
if ((objContext != null) && (objContext.trim().length() > 0))
{
currentFormNo = Integer.parseInt(objContext);
}
valueXmlString = new StringBuffer(
"<?xml version = \"1.0\"?> <Root> <header> <editFlag>");
valueXmlString = new StringBuffer("<?xml version = \"1.0\"?> <Root> <header> <editFlag>");
valueXmlString.append(editFlag).append("</editFlag> </header>");
switch (currentFormNo) {
switch (currentFormNo)
{
case 1:
parentNodeList = dom.getElementsByTagName("Detail1");
parentNode = parentNodeList.item(0);
childNodeList = parentNode.getChildNodes();
valueXmlString.append("<Detail1>");
int childNodeListLength = childNodeList.getLength();
tranId = checkNull(this.genericUtility.getColumnValue(
"tran_id", dom));
System.out.println("tran id from boqdet --4-->>>>[" + tranId
+ "]");
for (ctr = 0; ctr < childNodeListLength; ctr++) {
tranId = checkNull(this.genericUtility.getColumnValue("tran_id", dom));
System.out.println("tran id from boqdet --4-->>>>[" + tranId + "]");
for (ctr = 0; ctr < childNodeListLength; ctr++)
{
childNode = childNodeList.item(ctr);
childNodeName = childNode.getNodeName();
System.out.println("CURRENT COLUMN IN VALIDATION ["+ childNodeName + "]");
if (childNodeName.equalsIgnoreCase("cust_code")) {
System.out.println("CURRENT COLUMN IN VALIDATION [" + childNodeName + "]");
if (childNodeName.equalsIgnoreCase("cust_code"))
{
custCode = this.genericUtility.getColumnValue("cust_code", dom);
sql = "select key_flag from transetup where tran_window = 'w_customer'";
// sql = "select key_flag from transetup where tran_window = 'w_customer_test'";
pstmt = conn.prepareStatement(sql);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
keyFlag = rs.getString("key_flag");
}
rs.close();
......@@ -138,22 +139,26 @@ implements CustomerLocal, CustomerRemote {
pstmt.close();
pstmt = null;
if(keyFlag==null){
keyFlag="M";
if (keyFlag == null)
{
keyFlag = "M";
}
System.out.println("Key flag is :-["+keyFlag+"]");
if(keyFlag.equalsIgnoreCase("M") && (custCode==null || custCode.trim().length()<=0)){
System.out.println("Key flag is :-[" + keyFlag + "]");
if ("M".equalsIgnoreCase(keyFlag) && (custCode == null || custCode.trim().length() <= 0))
{
System.out.print("Throw error....");
errCode = "VMCODNULL";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}else if(editFlag.equalsIgnoreCase("A")){
cnt=0;
} else if ("A".equalsIgnoreCase(editFlag))
{
cnt = 0;
sql = "select count(*) as ll_count from customer where cust_code =?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, custCode);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
cnt = rs.getInt("ll_count");
}
rs.close();
......@@ -161,119 +166,142 @@ implements CustomerLocal, CustomerRemote {
pstmt.close();
pstmt = null;
if(cnt>0){
if (cnt > 0)
{
errCode = "VMDUPL1";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}
}else if(childNodeName.equalsIgnoreCase("cust_name")){
} else if (childNodeName.equalsIgnoreCase("cust_name"))
{
custName = this.genericUtility.getColumnValue("cust_name", dom);
if(custName==null || custName.trim().length()<=0){
errCode = "VMCNAMENLL";//Name is blank
if (custName == null || custName.trim().length() <= 0)
{
errCode = "VMCNAMENLL";// Name is blank
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}
else if(childNodeName.equalsIgnoreCase("sh_name")){
} else if (childNodeName.equalsIgnoreCase("sh_name"))
{
shName = this.genericUtility.getColumnValue("sh_name", dom);
if(shName==null || shName.trim().length()<=0){
errCode = "VMSHNAMNLL";//Short Name is blank
if (shName == null || shName.trim().length() <= 0)
{
errCode = "VMSHNAMNLL";// Short Name is blank
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}
else if(childNodeName.equalsIgnoreCase("available_yn")){
} else if (childNodeName.equalsIgnoreCase("available_yn"))
{
availableYn = this.genericUtility.getColumnValue("available_yn", dom);
if(availableYn==null || availableYn.trim().length()<=0){
errCode = "VMAVLBNULL";//Available Name is blank
if (availableYn == null || availableYn.trim().length() <= 0)
{
errCode = "VMAVLBNULL";// Available Name is blank
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}
else if(childNodeName.equalsIgnoreCase("round")){
} else if (childNodeName.equalsIgnoreCase("round"))
{
round = this.genericUtility.getColumnValue("round", dom);
if(round==null || round.trim().length()<=0){
errCode = "VMROUNDNLL";//Round Name is blank
if (round == null || round.trim().length() <= 0)
{
errCode = "VMROUNDNLL";// Round Name is blank
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}else if(childNodeName.equalsIgnoreCase("round_to")){
} else if (childNodeName.equalsIgnoreCase("round_to"))
{
roundTo = this.genericUtility.getColumnValue("round_to", dom);
if(roundTo==null || roundTo.trim().length()<=0){
errCode = "VMRNDTONLL";//Round To Name is blank
if (roundTo == null || roundTo.trim().length() <= 0)
{
errCode = "VMRNDTONLL";// Round To Name is blank
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}else if(childNodeName.equalsIgnoreCase("curr_code__frt")){
} else if (childNodeName.equalsIgnoreCase("curr_code__frt"))
{
currCodeFrt = this.genericUtility.getColumnValue("curr_code__frt", dom);
if(currCodeFrt==null || currCodeFrt.trim().length()<=0){
errCode = "VMCRCDFRNL";//Fright Currency is blank
if (currCodeFrt == null || currCodeFrt.trim().length() <= 0)
{
errCode = "VMCRCDFRNL";// Fright Currency is blank
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}else if(childNodeName.equalsIgnoreCase("curr_code__ins")){
} else if (childNodeName.equalsIgnoreCase("curr_code__ins"))
{
currCodeIns = this.genericUtility.getColumnValue("curr_code__ins", dom);
if(currCodeIns==null || currCodeIns.trim().length()<=0){
errCode = "VMINSCRRNL";//Insurance Currency is blank
if (currCodeIns == null || currCodeIns.trim().length() <= 0)
{
errCode = "VMINSCRRNL";// Insurance Currency is
// blank
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}
else if(childNodeName.equalsIgnoreCase("ignore_credit")){
} else if (childNodeName.equalsIgnoreCase("ignore_credit"))
{
ignoreCredit = this.genericUtility.getColumnValue("ignore_credit", dom);
cnt=0;
if(ignoreCredit!=null && ignoreCredit.trim().length()>0){
cnt=Integer.parseInt(ignoreCredit.trim());
if(cnt<0){
cnt = 0;
if (ignoreCredit != null && ignoreCredit.trim().length() > 0)
{
cnt = Integer.parseInt(ignoreCredit.trim());
if (cnt < 0)
{
errCode = "VMIGCRT";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}else{
} else
{
errCode = "VMIGCRTNLL";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}else if(childNodeName.equalsIgnoreCase("credit_lmt")){
} else if (childNodeName.equalsIgnoreCase("credit_lmt"))
{
creditLmt = this.genericUtility.getColumnValue("credit_lmt", dom);
if(creditLmt==null){
if (creditLmt == null)
{
errCode = "VMCRTLMNLL";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}
else if(childNodeName.equalsIgnoreCase("ignore_days")){
} else if (childNodeName.equalsIgnoreCase("ignore_days"))
{
ignoreDays = this.genericUtility.getColumnValue("ignore_days", dom);
cnt=0;
if(ignoreDays!=null && ignoreDays.trim().length()>0){
cnt=Integer.parseInt(ignoreDays.trim());
if(cnt<0){
cnt = 0;
if (ignoreDays != null && ignoreDays.trim().length() > 0)
{
cnt = Integer.parseInt(ignoreDays.trim());
if (cnt < 0)
{
errCode = "VMCRDYS";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}
}else if(childNodeName.equalsIgnoreCase("acct_code__adv")){
} else if (childNodeName.equalsIgnoreCase("acct_code__adv"))
{
acctCodeAdv = this.genericUtility.getColumnValue("acct_code__adv", dom);
if(acctCodeAdv!=null){
cnt=0;
if (acctCodeAdv != null)
{
cnt = 0;
sql = "select count(*) as cnt from accounts where acct_code =?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, acctCodeAdv);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
cnt = rs.getInt("cnt");
}
rs.close();
......@@ -281,12 +309,14 @@ implements CustomerLocal, CustomerRemote {
pstmt.close();
pstmt = null;
if(cnt!=0){
if (cnt != 0)
{
sql = "select active from accounts where acct_code =?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, acctCodeAdv);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
active = rs.getString("active");
}
rs.close();
......@@ -294,30 +324,35 @@ implements CustomerLocal, CustomerRemote {
pstmt.close();
pstmt = null;
if(!active.equalsIgnoreCase("Y")){
if (!active.equalsIgnoreCase("Y"))
{
errCode = "VMACCTA";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}else{
} else
{
errCode = "VTACCTCD1";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}else{
errCode = "VTACCTNLL";//Account adv null
} else
{
errCode = "VTACCTNLL";// Account adv null
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}else if(childNodeName.equalsIgnoreCase("cctr_code__adv")){
} else if (childNodeName.equalsIgnoreCase("cctr_code__adv"))
{
cctrCodeAdv = this.genericUtility.getColumnValue("cctr_code__adv", dom);
cnt=0;
cnt = 0;
sql = "select count(*) as cnt from costctr where cctr_code =?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, cctrCodeAdv);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
cnt = rs.getInt("cnt");
}
rs.close();
......@@ -325,23 +360,28 @@ implements CustomerLocal, CustomerRemote {
pstmt.close();
pstmt = null;
if(cnt==0){
if (cnt == 0)
{
errCode = "VTCCTRCD1";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}else if(childNodeName.equalsIgnoreCase("group_code")){
} else if (childNodeName.equalsIgnoreCase("group_code"))
{
groupCode = this.genericUtility.getColumnValue("group_code", dom);
custCode = this.genericUtility.getColumnValue("cust_code", dom);
if(groupCode!=null && groupCode.trim().length()>0){
if(!groupCode.equalsIgnoreCase(custCode)){
cnt=0;
if (groupCode != null && groupCode.trim().length() > 0)
{
if (!groupCode.equalsIgnoreCase(custCode))
{
cnt = 0;
sql = "select count(*) as cnt from customer where cust_code =?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, groupCode);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
cnt = rs.getInt("cnt");
}
rs.close();
......@@ -351,9 +391,9 @@ implements CustomerLocal, CustomerRemote {
sql = "select key_flag from transetup where tran_window = 'w_customer'";
pstmt = conn.prepareStatement(sql);
//pstmt.setString(1, groupCode);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
keyFlag = rs.getString("key_flag");
}
rs.close();
......@@ -361,26 +401,29 @@ implements CustomerLocal, CustomerRemote {
pstmt.close();
pstmt = null;
if(cnt==0 && !(keyFlag.equalsIgnoreCase("A"))){
if (cnt == 0 && !("A".equalsIgnoreCase(keyFlag)))
{
errCode = "VMCUST1";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}
}else{
errCode = "VMGRPCNULL";//Group Code is null
} else
{
errCode = "VMGRPCNULL";// Group Code is null
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}else if(childNodeName.equalsIgnoreCase("cust_code__bil")){
} else if (childNodeName.equalsIgnoreCase("cust_code__bil"))
{
custCodeBil = this.genericUtility.getColumnValue("cust_code__bil", dom);
custCode = this.genericUtility.getColumnValue("cust_code", dom);
sql = "select key_flag from transetup where tran_window = 'w_customer'";
pstmt = conn.prepareStatement(sql);
// pstmt.setString(1, groupCode);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
keyFlag = rs.getString("key_flag");
}
rs.close();
......@@ -388,17 +431,20 @@ implements CustomerLocal, CustomerRemote {
pstmt.close();
pstmt = null;
if((custCodeBil!=null || custCodeBil.trim().length()>0) && !(keyFlag.equalsIgnoreCase("A"))){
if ((custCodeBil != null || custCodeBil.trim().length() > 0) && !("A".equalsIgnoreCase(keyFlag)))
{
errCode = "VEBILLTO";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}else if(!custCodeBil.equalsIgnoreCase(custCode)){
cnt=0;
} else if (!custCodeBil.equalsIgnoreCase(custCode))
{
cnt = 0;
sql = "select count(*) as cnt from customer where cust_code =?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, custCodeBil);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
cnt = rs.getInt("cnt");
}
rs.close();
......@@ -406,26 +452,31 @@ implements CustomerLocal, CustomerRemote {
pstmt.close();
pstmt = null;
if(cnt==0){
if (cnt == 0)
{
errCode = "VMBILLTO";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}else if(custCodeBil==null){
} else if (custCodeBil == null || custCodeBil.trim().length() <= 0)
{
errCode = "VMBLLTONLL";// Bill To is null
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}else if(childNodeName.equalsIgnoreCase("stan_code")){
} else if (childNodeName.equalsIgnoreCase("stan_code"))
{
stanCode = this.genericUtility.getColumnValue("stan_code", dom);
cnt=0;
cnt = 0;
if(stanCode!=null){
if (stanCode != null)
{
sql = "select count(*) as cnt from station where stan_code =?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, stanCode);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
cnt = rs.getInt("cnt");
}
rs.close();
......@@ -433,26 +484,31 @@ implements CustomerLocal, CustomerRemote {
pstmt.close();
pstmt = null;
if(cnt==0){
if (cnt == 0)
{
errCode = "VTSTAN1";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}else{
} else
{
errCode = "VMSTNCDNLL";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}else if(childNodeName.equalsIgnoreCase("terr_code")){
} else if (childNodeName.equalsIgnoreCase("terr_code"))
{
terrCode = this.genericUtility.getColumnValue("terr_code", dom);
if(terrCode!=null && terrCode.trim().length()>0){
cnt=0;
if (terrCode != null && terrCode.trim().length() > 0)
{
cnt = 0;
sql = "select count(*) as ll_count from territory where terr_code =?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, terrCode);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
cnt = rs.getInt("ll_count");
}
rs.close();
......@@ -460,22 +516,26 @@ implements CustomerLocal, CustomerRemote {
pstmt.close();
pstmt = null;
if(cnt==0){
if (cnt == 0)
{
errCode = "VTTERRCD";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}
}else if(childNodeName.equalsIgnoreCase("state_code")){
} else if (childNodeName.equalsIgnoreCase("state_code"))
{
stateCode = this.genericUtility.getColumnValue("state_code", dom);
if(stateCode!=null && stateCode.trim().length()>0){
cnt=0;
if (stateCode != null && stateCode.trim().length() > 0)
{
cnt = 0;
sql = "select count(*) as cnt from state where state_code =?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, stateCode);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
cnt = rs.getInt("cnt");
}
rs.close();
......@@ -483,22 +543,26 @@ implements CustomerLocal, CustomerRemote {
pstmt.close();
pstmt = null;
if(cnt==0){
if (cnt == 0)
{
errCode = "VTSTATE1";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}
}else if(childNodeName.equalsIgnoreCase("count_code")){
} else if (childNodeName.equalsIgnoreCase("count_code"))
{
countCode = this.genericUtility.getColumnValue("count_code", dom);
if(countCode!=null && countCode.trim().length()>0){
cnt=0;
if (countCode != null && countCode.trim().length() > 0)
{
cnt = 0;
sql = "select count(*) as cnt from country where count_code =?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, countCode);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
cnt = rs.getInt("cnt");
}
rs.close();
......@@ -506,22 +570,26 @@ implements CustomerLocal, CustomerRemote {
pstmt.close();
pstmt = null;
if(cnt==0){
if (cnt == 0)
{
errCode = "VTCONTCD1";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}
}else if(childNodeName.equalsIgnoreCase("cr_term")){
} else if (childNodeName.equalsIgnoreCase("cr_term"))
{
crTerm = this.genericUtility.getColumnValue("cr_term", dom);
if(crTerm!=null && crTerm.trim().length()>0){
cnt=0;
if (crTerm != null && crTerm.trim().length() > 0)
{
cnt = 0;
sql = "select count(*) as cnt from crterm where cr_term =?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, crTerm);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
cnt = rs.getInt("cnt");
}
rs.close();
......@@ -529,21 +597,24 @@ implements CustomerLocal, CustomerRemote {
pstmt.close();
pstmt = null;
if(cnt==0){
if (cnt == 0)
{
errCode = "VTCRTERM1";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}
}else if(childNodeName.equalsIgnoreCase("curr_code")){
} else if (childNodeName.equalsIgnoreCase("curr_code"))
{
currCode = this.genericUtility.getColumnValue("curr_code", dom);
cnt=0;
cnt = 0;
sql = "select count(*) as cnt from currency where curr_code =?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, currCode);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
cnt = rs.getInt("cnt");
}
rs.close();
......@@ -551,19 +622,23 @@ implements CustomerLocal, CustomerRemote {
pstmt.close();
pstmt = null;
if(cnt==0){
if (cnt == 0)
{
errCode = "VTCURRCD1";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}else{
if(editFlag.equalsIgnoreCase("E")){
} else
{
if (editFlag.equalsIgnoreCase("E"))
{
custCode = this.genericUtility.getColumnValue("cust_code", dom);
sql = "select curr_code from customer where cust_code =?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, custCode);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
currCode1 = rs.getString("curr_code");
}
rs.close();
......@@ -571,19 +646,18 @@ implements CustomerLocal, CustomerRemote {
pstmt.close();
pstmt = null;
if(!currCode.equalsIgnoreCase(currCode1) && currCode1!=null){
lsVal3="C";
cnt=0;
if (!currCode.equalsIgnoreCase(currCode1) && currCode1 != null)
{
lsVal3 = "C";
cnt = 0;
sql = "select count(distinct curr_code__ac) as ll_count from sundrybal"
+ " where sundry_code =?"
+ " and sundry_type =?"
+ " and (dr_amt != 0 or cr_amt != 0)";
sql = "select count(distinct curr_code__ac) as ll_count from sundrybal" + " where sundry_code =?" + " and sundry_type =?" + " and (dr_amt != 0 or cr_amt != 0)";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, custCode);
pstmt.setString(2, lsVal3);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
cnt = rs.getInt("ll_count");
}
rs.close();
......@@ -591,18 +665,15 @@ implements CustomerLocal, CustomerRemote {
pstmt.close();
pstmt = null;
cnt1=0;
sql = "select count(*) as cnt from sundrybal"
+ " where sundry_code = ?"
+ " and sundry_type = ?"
+ " and (dr_amt != 0 or cr_amt != 0)"
+ " and curr_code__ac = ?";
cnt1 = 0;
sql = "select count(*) as cnt from sundrybal" + " where sundry_code = ?" + " and sundry_type = ?" + " and (dr_amt != 0 or cr_amt != 0)" + " and curr_code__ac = ?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, custCode);
pstmt.setString(2, lsVal3);
pstmt.setString(3, currCode1);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
cnt1 = rs.getInt("ll_count");
}
rs.close();
......@@ -610,7 +681,8 @@ implements CustomerLocal, CustomerRemote {
pstmt.close();
pstmt = null;
if(cnt1!=0 && cnt>1){
if (cnt1 != 0 && cnt > 1)
{
errCode = "VXCURRCD1";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
......@@ -618,16 +690,19 @@ implements CustomerLocal, CustomerRemote {
}
}
}
}else if(childNodeName.equalsIgnoreCase("acct_code__ar")){
} else if (childNodeName.equalsIgnoreCase("acct_code__ar"))
{
acctCodeAr = this.genericUtility.getColumnValue("acct_code__ar", dom);
if(acctCodeAr!=null && acctCodeAr.trim().length()>0){
cnt=0;
if (acctCodeAr != null && acctCodeAr.trim().length() > 0)
{
cnt = 0;
sql = "select count(*) as cnt from accounts where acct_code = ?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, acctCodeAr);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
cnt = rs.getInt("cnt");
}
rs.close();
......@@ -635,12 +710,14 @@ implements CustomerLocal, CustomerRemote {
pstmt.close();
pstmt = null;
if(cnt!=0){
if (cnt != 0)
{
sql = "select active from accounts where acct_code =?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, acctCodeAr);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
active = rs.getString("active");
}
rs.close();
......@@ -648,31 +725,37 @@ implements CustomerLocal, CustomerRemote {
pstmt.close();
pstmt = null;
if(!active.equalsIgnoreCase("Y")){
if (!"Y".equalsIgnoreCase(active))
{
errCode = "VMACCTA";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}else{
} else
{
errCode = "VTACCTCD1";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}else {
} else
{
errCode = "VMACCTNLL";// A/C Rec is null
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}else if(childNodeName.equalsIgnoreCase("cctr_code__ar")){
} else if (childNodeName.equalsIgnoreCase("cctr_code__ar"))
{
cctrCodeAr = this.genericUtility.getColumnValue("cctr_code__ar", dom);
if(cctrCodeAr!=null && cctrCodeAr.trim().length()>0){
cnt=0;
if (cctrCodeAr != null && cctrCodeAr.trim().length() > 0)
{
cnt = 0;
sql = "select count(*) as cnt from costctr where cctr_code =?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, cctrCodeAr);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
cnt = rs.getInt("cnt");
}
rs.close();
......@@ -680,30 +763,36 @@ implements CustomerLocal, CustomerRemote {
pstmt.close();
pstmt = null;
if(cnt==0){
if (cnt == 0)
{
errCode = "VTCCTRCD1";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}else{
} else
{
acctCodeAr = this.genericUtility.getColumnValue("acct_code__ar", dom);
if(acctCodeAr!=null && acctCodeAr.trim().length()>0){
if (acctCodeAr != null && acctCodeAr.trim().length() > 0)
{
valueXmlString.append("<cctr_code__ar ><![CDATA[" + blankVar + "]]></cctr_code__ar>");
}
errCode = "VTCCTRNLL";//Cost Center null
errCode = "VTCCTRNLL";// Cost Center null
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}else if(childNodeName.equalsIgnoreCase("tax_class")){
} else if (childNodeName.equalsIgnoreCase("tax_class"))
{
taxClass = this.genericUtility.getColumnValue("tax_class", dom);
if(taxClass!=null && taxClass.trim().length()>0){
cnt=0;
if (taxClass != null && taxClass.trim().length() > 0)
{
cnt = 0;
sql = "select count(*) as cnt from taxclass where tax_class =?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, taxClass);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
cnt = rs.getInt("cnt");
}
rs.close();
......@@ -711,22 +800,26 @@ implements CustomerLocal, CustomerRemote {
pstmt.close();
pstmt = null;
if(cnt==0){
if (cnt == 0)
{
errCode = "VTTAXCLA1";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}
}else if(childNodeName.equalsIgnoreCase("tax_chap")){
} else if (childNodeName.equalsIgnoreCase("tax_chap"))
{
taxChap = this.genericUtility.getColumnValue("tax_chap", dom);
if(taxChap!=null && taxChap.trim().length()>0){
cnt=0;
if (taxChap != null && taxChap.trim().length() > 0)
{
cnt = 0;
sql = "select count(*) as cnt from taxchap where tax_chap =?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, taxChap);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
cnt = rs.getInt("cnt");
}
rs.close();
......@@ -734,22 +827,26 @@ implements CustomerLocal, CustomerRemote {
pstmt.close();
pstmt = null;
if(cnt==0){
if (cnt == 0)
{
errCode = "VTTAXCHAP1";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}
}else if(childNodeName.equalsIgnoreCase("price_list")){
} else if (childNodeName.equalsIgnoreCase("price_list"))
{
priceList = this.genericUtility.getColumnValue("price_list", dom);
if(priceList!=null && priceList.trim().length()>0){
cnt=0;
if (priceList != null && priceList.trim().length() > 0)
{
cnt = 0;
sql = "select count(*) as cnt from pricelist_mst where price_list =?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, priceList);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
cnt = rs.getInt("cnt");
}
rs.close();
......@@ -757,22 +854,26 @@ implements CustomerLocal, CustomerRemote {
pstmt.close();
pstmt = null;
if(cnt==0){
if (cnt == 0)
{
errCode = "VTPLIST1";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}
}else if(childNodeName.equalsIgnoreCase("price_list__clg")){
} else if (childNodeName.equalsIgnoreCase("price_list__clg"))
{
priceListClg = this.genericUtility.getColumnValue("price_list__clg", dom);
if(priceListClg!=null && priceListClg.trim().length()>0){
cnt=0;
if (priceListClg != null && priceListClg.trim().length() > 0)
{
cnt = 0;
sql = "select count(*) as cnt from pricelist_mst where price_list =?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, priceListClg);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
cnt = rs.getInt("cnt");
}
rs.close();
......@@ -780,23 +881,26 @@ implements CustomerLocal, CustomerRemote {
pstmt.close();
pstmt = null;
if(cnt==0){
if (cnt == 0)
{
errCode = "VTPLIST1";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}
}
else if(childNodeName.equalsIgnoreCase("sales_pers")){
} else if (childNodeName.equalsIgnoreCase("sales_pers"))
{
salesPers = this.genericUtility.getColumnValue("sales_pers", dom);
if(salesPers!=null && salesPers.trim().length()>0){
cnt=0;
if (salesPers != null && salesPers.trim().length() > 0)
{
cnt = 0;
sql = "select count(*) as cnt from sales_pers where sales_pers = ?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, salesPers);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
cnt = rs.getInt("cnt");
}
rs.close();
......@@ -804,26 +908,30 @@ implements CustomerLocal, CustomerRemote {
pstmt.close();
pstmt = null;
if(cnt==0){
if (cnt == 0)
{
errCode = "VMSLPERS1";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}else{
} else
{
errCode = "VMSLPERNLL";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}
else if(childNodeName.equalsIgnoreCase("sales_pers__1")){
} else if (childNodeName.equalsIgnoreCase("sales_pers__1"))
{
salesPers1 = this.genericUtility.getColumnValue("sales_pers__1", dom);
if(salesPers1!=null && salesPers1.trim().length()>0){
cnt=0;
if (salesPers1 != null && salesPers1.trim().length() > 0)
{
cnt = 0;
sql = "select count(*) as cnt from sales_pers where sales_pers = ?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, salesPers1);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
cnt = rs.getInt("cnt");
}
rs.close();
......@@ -831,22 +939,25 @@ implements CustomerLocal, CustomerRemote {
pstmt.close();
pstmt = null;
if(cnt==0){
if (cnt == 0)
{
errCode = "VMSLPERS1";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}
}
else if(childNodeName.equalsIgnoreCase("sales_pers__2")){
} else if (childNodeName.equalsIgnoreCase("sales_pers__2"))
{
salesPers2 = this.genericUtility.getColumnValue("sales_pers__2", dom);
if(salesPers2!=null && salesPers2.trim().length()>0){
cnt=0;
if (salesPers2 != null && salesPers2.trim().length() > 0)
{
cnt = 0;
sql = "select count(*) as cnt from sales_pers where sales_pers = ?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, salesPers2);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
cnt = rs.getInt("cnt");
}
rs.close();
......@@ -854,23 +965,26 @@ implements CustomerLocal, CustomerRemote {
pstmt.close();
pstmt = null;
if(cnt==0){
if (cnt == 0)
{
errCode = "VMSLPERS1";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}
}
else if(childNodeName.equalsIgnoreCase("tran_code")){
} else if (childNodeName.equalsIgnoreCase("tran_code"))
{
tranCode = this.genericUtility.getColumnValue("tran_code", dom);
if(tranCode!=null && tranCode.trim().length()>0){
cnt=0;
if (tranCode != null && tranCode.trim().length() > 0)
{
cnt = 0;
sql = "select count(*) as cnt from transporter where tran_code = ?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, tranCode);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
cnt = rs.getInt("cnt");
}
rs.close();
......@@ -878,22 +992,26 @@ implements CustomerLocal, CustomerRemote {
pstmt.close();
pstmt = null;
if(cnt==0){
if (cnt == 0)
{
errCode = "VTTRANCD1";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}
}else if(childNodeName.equalsIgnoreCase("site_code__rcp")){
} else if (childNodeName.equalsIgnoreCase("site_code__rcp"))
{
siteCodeRcp = this.genericUtility.getColumnValue("site_code__rcp", dom);
if(siteCodeRcp!=null && siteCodeRcp.trim().length()>0){
cnt=0;
if (siteCodeRcp != null && siteCodeRcp.trim().length() > 0)
{
cnt = 0;
sql = "select count(*) as cnt from site where site_code =?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, siteCodeRcp);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
cnt = rs.getInt("cnt");
}
rs.close();
......@@ -901,33 +1019,40 @@ implements CustomerLocal, CustomerRemote {
pstmt.close();
pstmt = null;
if(cnt==0){
if (cnt == 0)
{
errCode = "VTSITECD1";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}
}else if(childNodeName.equalsIgnoreCase("site_code")){
} else if (childNodeName.equalsIgnoreCase("site_code"))
{
siteCode = this.genericUtility.getColumnValue("site_code", dom);
channelPartner = this.genericUtility.getColumnValue("channel_partner", dom);
if(channelPartner.equalsIgnoreCase("Y") && (siteCode==null && siteCode.trim().length()<=0)){
if ("Y".equalsIgnoreCase(channelPartner) && (siteCode == null && siteCode.trim().length() <= 0))
{
errCode = "VMSITECD1";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}else{
if(channelPartner.equalsIgnoreCase("N") && (siteCode!=null)){
} else
{
if ("N".equalsIgnoreCase(channelPartner) && (siteCode != null))
{
errCode = "VNRSITE";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
if(channelPartner.equalsIgnoreCase("Y") && (siteCode!=null && siteCode.trim().length()>0)){
cnt=0;
if ("Y".equalsIgnoreCase(channelPartner) && (siteCode != null && siteCode.trim().length() > 0))
{
cnt = 0;
sql = "select count(*) as cnt from site where site_code =?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, siteCode);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
cnt = rs.getInt("cnt");
}
rs.close();
......@@ -935,30 +1060,35 @@ implements CustomerLocal, CustomerRemote {
pstmt.close();
pstmt = null;
if(cnt==0){
if (cnt == 0)
{
errCode = "VTSITECD1";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}
}
}else if(childNodeName.equalsIgnoreCase("black_listing")){
} else if (childNodeName.equalsIgnoreCase("black_listing"))
{
blackListing = this.genericUtility.getColumnValue("black_listing", dom);
if(!blackListing.equalsIgnoreCase("P")){
if (!"P".equalsIgnoreCase(blackListing))
{
errCode = "VMBLACKLIS";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}else if(childNodeName.equalsIgnoreCase("contact_code")){
} else if (childNodeName.equalsIgnoreCase("contact_code"))
{
contactCode = this.genericUtility.getColumnValue("contact_code", dom);
cnt=0;
cnt = 0;
sql = "select count(*) as cnt from contact where contact_code =?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, contactCode);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
cnt = rs.getInt("cnt");
}
rs.close();
......@@ -966,21 +1096,25 @@ implements CustomerLocal, CustomerRemote {
pstmt.close();
pstmt = null;
if(cnt==0){
if (cnt == 0)
{
errCode = "VMCONTCD1";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}else if(childNodeName.equalsIgnoreCase("bank_code")){
} else if (childNodeName.equalsIgnoreCase("bank_code"))
{
bankCode = this.genericUtility.getColumnValue("bank_code", dom);
if(bankCode!=null){
cnt=0;
if (bankCode != null)
{
cnt = 0;
sql = "select count(*) as cnt from bank where bank_code =?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, bankCode);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
cnt = rs.getInt("cnt");
}
rs.close();
......@@ -988,25 +1122,29 @@ implements CustomerLocal, CustomerRemote {
pstmt.close();
pstmt = null;
if(cnt<=0){
if (cnt <= 0)
{
errCode = "VMBANK1";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}
}else if(childNodeName.equalsIgnoreCase("price_list__disc")){
} else if (childNodeName.equalsIgnoreCase("price_list__disc"))
{
priceListDisc = this.genericUtility.getColumnValue("price_list__disc", dom);
if(priceListDisc!=null && priceListDisc.trim().length()>0){
// cnt1=Integer.parseInt(priceListDisc.trim());
// }
// if(cnt1>0){
cnt=0;
if (priceListDisc != null && priceListDisc.trim().length() > 0)
{
// cnt1=Integer.parseInt(priceListDisc.trim());
// }
// if(cnt1>0){
cnt = 0;
sql = "select count(*) as cnt from pricelist where price_list =?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, priceListDisc);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
cnt = rs.getInt("cnt");
}
rs.close();
......@@ -1014,30 +1152,36 @@ implements CustomerLocal, CustomerRemote {
pstmt.close();
pstmt = null;
if(cnt==0){
if (cnt == 0)
{
errCode = "VTPLIST1";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}
}else if(childNodeName.equalsIgnoreCase("sales_option")){
} else if (childNodeName.equalsIgnoreCase("sales_option"))
{
salesOption = this.genericUtility.getColumnValue("sales_option", dom);
if(salesOption==null || salesOption.trim().length()<=0){
if (salesOption == null || salesOption.trim().length() <= 0)
{
errCode = "VTSLOPT";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}else if(childNodeName.equalsIgnoreCase("dlv_term")){
} else if (childNodeName.equalsIgnoreCase("dlv_term"))
{
dlvTerm = this.genericUtility.getColumnValue("dlv_term", dom);
if(dlvTerm!=null || dlvTerm.trim().length()>0){
cnt=0;
if (dlvTerm != null || dlvTerm.trim().length() > 0)
{
cnt = 0;
sql = "select count(*) as cnt from delivery_term where dlv_term =?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, dlvTerm);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
cnt = rs.getInt("cnt");
}
rs.close();
......@@ -1045,47 +1189,57 @@ implements CustomerLocal, CustomerRemote {
pstmt.close();
pstmt = null;
if(cnt==0){
if (cnt == 0)
{
errCode = "VMDLVTERM1";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}
}else if(childNodeName.equalsIgnoreCase("loss_perc")){
} else if (childNodeName.equalsIgnoreCase("loss_perc"))
{
lossPerc = this.genericUtility.getColumnValue("loss_perc", dom);
if(lossPerc!=null){
cnt1=Integer.parseInt(lossPerc);
if (lossPerc != null)
{
cnt1 = Integer.parseInt(lossPerc);
}
if(cnt1<0){
if (cnt1 < 0)
{
errCode = "VTLOSSPERC";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}else if(childNodeName.equalsIgnoreCase("adhoc_repl_perc")){
} else if (childNodeName.equalsIgnoreCase("adhoc_repl_perc"))
{
adhocReplPerc = this.genericUtility.getColumnValue("adhoc_repl_perc", dom);
double adhocvalue=0.00;
double adhocvalue = 0.00;
if(adhocReplPerc!=null||adhocReplPerc.trim().length()>0){
if (adhocReplPerc != null || adhocReplPerc.trim().length() > 0)
{
adhocvalue=Double.valueOf(adhocReplPerc.trim());
// cnt1=Integer.parseInt(adhocReplPerc.trim());
// if(cnt1<0 || cnt1>100){
if(adhocvalue<0 || adhocvalue>100){
adhocvalue = Double.valueOf(adhocReplPerc.trim());
// cnt1=Integer.parseInt(adhocReplPerc.trim());
// if(cnt1<0 || cnt1>100){
if (adhocvalue < 0 || adhocvalue > 100)
{
errCode = "VTADH";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}
}else if(childNodeName.equalsIgnoreCase("term_table__no")){
} else if (childNodeName.equalsIgnoreCase("term_table__no"))
{
termTableNo = this.genericUtility.getColumnValue("term_table__no", dom);
if(termTableNo!=null){
if (termTableNo != null)
{
sql = "select count(1) as cnt from sale_term_table where term_table = ?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, termTableNo);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
cnt = rs.getInt("cnt");
}
rs.close();
......@@ -1093,23 +1247,26 @@ implements CustomerLocal, CustomerRemote {
pstmt.close();
pstmt = null;
if(cnt==0){
if (cnt == 0)
{
errCode = "VMSALETERM";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}
}else if(childNodeName.equalsIgnoreCase("emp_code__ord")){
} else if (childNodeName.equalsIgnoreCase("emp_code__ord"))
{
empCodeOrd = checkNull(this.genericUtility.getColumnValue("emp_code__ord", dom));
if(empCodeOrd!=null && empCodeOrd.trim().length()>0){
cnt=0;
if (empCodeOrd != null && empCodeOrd.trim().length() > 0)
{
cnt = 0;
sql = "select count(*) as cnt from employee where emp_code=?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, empCodeOrd);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
cnt = rs.getInt("cnt");
}
rs.close();
......@@ -1117,23 +1274,27 @@ implements CustomerLocal, CustomerRemote {
pstmt.close();
pstmt = null;
if(cnt==0){
if (cnt == 0)
{
errCode = "VMEMPORD2";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}
}else if(childNodeName.equalsIgnoreCase("emp_code__ord1")){
} else if (childNodeName.equalsIgnoreCase("emp_code__ord1"))
{
empCodeOrd1 = checkNull(this.genericUtility.getColumnValue("emp_code__ord1", dom));
if(empCodeOrd1!=null && empCodeOrd1.trim().length()>0){
cnt=0;
if (empCodeOrd1 != null && empCodeOrd1.trim().length() > 0)
{
cnt = 0;
sql = "select count(*) as cnt from employee where emp_code=?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, empCodeOrd1);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
cnt = rs.getInt("cnt");
}
rs.close();
......@@ -1141,113 +1302,123 @@ implements CustomerLocal, CustomerRemote {
pstmt.close();
pstmt = null;
if(cnt==0){
if (cnt == 0)
{
errCode = "VMEMPORD2";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}
}
// else if(childNodeName.equalsIgnoreCase("cust_code__pd")){
// custCodePd = checkNull(this.genericUtility.getColumnValue(
// "cust_code__pd", dom));
//
// if(custCodePd!=null){
// cnt=0;
// sql = "select count(*) as cnt from customer where cust_code__pd=?";
// pstmt = conn.prepareStatement(sql);
// pstmt.setString(1, custCodePd);
// rs = pstmt.executeQuery();
// if (rs.next()) {
// cnt = rs.getInt("cnt");
// }
// rs.close();
// rs = null;
// pstmt.close();
// pstmt = null;
//
// if(cnt==0){
// errCode = "";
// errList.add(errCode);
// errFields.add(childNodeName.toLowerCase());
// }
// }
// }
// else if(childNodeName.equalsIgnoreCase("cust_code__disc")){
// custCodeDisc = checkNull(this.genericUtility.getColumnValue(
// "cust_code__disc", dom));
//
// if(custCodeDisc!=null){
// cnt=0;
// sql = "select count(*) as cnt from customer where cust_code__disc=?";
// pstmt = conn.prepareStatement(sql);
// pstmt.setString(1, custCodeDisc);
// rs = pstmt.executeQuery();
// if (rs.next()) {
// cnt = rs.getInt("cnt");
// }
// rs.close();
// rs = null;
// pstmt.close();
// pstmt = null;
//
// if(cnt==0){
// errCode = "";
// errList.add(errCode);
// errFields.add(childNodeName.toLowerCase());
// }
// }
// }
// else if(childNodeName.equalsIgnoreCase("sgroup_code")){
// sgroupCode = checkNull(this.genericUtility.getColumnValue(
// "sgroup_code", dom));
//
// if(sgroupCode!=null){
// cnt=0;
// sql = "select count(*) as cnt from acctsgrp where sgroup_code=?";
// pstmt = conn.prepareStatement(sql);
// pstmt.setString(1, sgroupCode);
// rs = pstmt.executeQuery();
// if (rs.next()) {
// cnt = rs.getInt("cnt");
// }
// rs.close();
// rs = null;
// pstmt.close();
// pstmt = null;
//
// if(cnt==0){
// errCode = "";
// errList.add(errCode);
// errFields.add(childNodeName.toLowerCase());
// }
// }
// }
// else if(childNodeName.equalsIgnoreCase("cust_code__ar")){
// custCodeAr = checkNull(this.genericUtility.getColumnValue(
// "cust_code__ar", dom));
//
// if(custCodeAr!=null){
// cnt=0;
// sql = "select count(*) as cnt from customer where cust_code__ar=?";
// pstmt = conn.prepareStatement(sql);
// pstmt.setString(1, custCodeAr);
// rs = pstmt.executeQuery();
// if (rs.next()) {
// cnt = rs.getInt("cnt");
// }
// rs.close();
// rs = null;
// pstmt.close();
// pstmt = null;
//
// if(cnt==0){
// errCode = "";
// errList.add(errCode);
// errFields.add(childNodeName.toLowerCase());
// }
// }
// }
// else if(childNodeName.equalsIgnoreCase("cust_code__pd")){
// custCodePd =
// checkNull(this.genericUtility.getColumnValue(
// "cust_code__pd", dom));
//
// if(custCodePd!=null){
// cnt=0;
// sql =
// "select count(*) as cnt from customer where cust_code__pd=?";
// pstmt = conn.prepareStatement(sql);
// pstmt.setString(1, custCodePd);
// rs = pstmt.executeQuery();
// if (rs.next()) {
// cnt = rs.getInt("cnt");
// }
// rs.close();
// rs = null;
// pstmt.close();
// pstmt = null;
//
// if(cnt==0){
// errCode = "";
// errList.add(errCode);
// errFields.add(childNodeName.toLowerCase());
// }
// }
// }
// else
// if(childNodeName.equalsIgnoreCase("cust_code__disc")){
// custCodeDisc =
// checkNull(this.genericUtility.getColumnValue(
// "cust_code__disc", dom));
//
// if(custCodeDisc!=null){
// cnt=0;
// sql =
// "select count(*) as cnt from customer where cust_code__disc=?";
// pstmt = conn.prepareStatement(sql);
// pstmt.setString(1, custCodeDisc);
// rs = pstmt.executeQuery();
// if (rs.next()) {
// cnt = rs.getInt("cnt");
// }
// rs.close();
// rs = null;
// pstmt.close();
// pstmt = null;
//
// if(cnt==0){
// errCode = "";
// errList.add(errCode);
// errFields.add(childNodeName.toLowerCase());
// }
// }
// }
// else if(childNodeName.equalsIgnoreCase("sgroup_code")){
// sgroupCode =
// checkNull(this.genericUtility.getColumnValue(
// "sgroup_code", dom));
//
// if(sgroupCode!=null){
// cnt=0;
// sql =
// "select count(*) as cnt from acctsgrp where sgroup_code=?";
// pstmt = conn.prepareStatement(sql);
// pstmt.setString(1, sgroupCode);
// rs = pstmt.executeQuery();
// if (rs.next()) {
// cnt = rs.getInt("cnt");
// }
// rs.close();
// rs = null;
// pstmt.close();
// pstmt = null;
//
// if(cnt==0){
// errCode = "";
// errList.add(errCode);
// errFields.add(childNodeName.toLowerCase());
// }
// }
// }
// else if(childNodeName.equalsIgnoreCase("cust_code__ar")){
// custCodeAr =
// checkNull(this.genericUtility.getColumnValue(
// "cust_code__ar", dom));
//
// if(custCodeAr!=null){
// cnt=0;
// sql =
// "select count(*) as cnt from customer where cust_code__ar=?";
// pstmt = conn.prepareStatement(sql);
// pstmt.setString(1, custCodeAr);
// rs = pstmt.executeQuery();
// if (rs.next()) {
// cnt = rs.getInt("cnt");
// }
// rs.close();
// rs = null;
// pstmt.close();
// pstmt = null;
//
// if(cnt==0){
// errCode = "";
// errList.add(errCode);
// errFields.add(childNodeName.toLowerCase());
// }
// }
// }
}
valueXmlString.append("</Detail1>");
......@@ -1258,20 +1429,23 @@ implements CustomerLocal, CustomerRemote {
childNodeList = parentNode.getChildNodes();
valueXmlString.append("<Detail2>");
childNodeListLength = childNodeList.getLength();
System.out.println("editFlag -->>[" + editFlag + "]");
for (ctr = 0; ctr < childNodeListLength; ctr++) {
for (ctr = 0; ctr < childNodeListLength; ctr++)
{
childNode = childNodeList.item(ctr);
childNodeName = childNode.getNodeName();
if (childNodeName.trim().equalsIgnoreCase("reg_code")) {
if (childNodeName.trim().equalsIgnoreCase("reg_code"))
{
regCode = this.genericUtility.getColumnValue("reg_code", dom);
if(regCode!=null){
cnt=0;
if (regCode != null && regCode.trim().length()>0)
{
cnt = 0;
sql = "select count(*) as cnt from reg_requirements where reg_code=?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, regCode);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
cnt = rs.getInt("cnt");
}
rs.close();
......@@ -1279,41 +1453,47 @@ implements CustomerLocal, CustomerRemote {
pstmt.close();
pstmt = null;
if(cnt==0){
if (cnt == 0)
{
errCode = "VTRCODEXT";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}else {
} else
{
errCode = "VTRCODNULL";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
} else if(childNodeName.trim().equalsIgnoreCase("reg_date")){
} else if (childNodeName.trim().equalsIgnoreCase("reg_date"))
{
regDate = this.genericUtility.getColumnValue("reg_date", dom);
if(regDate==null || regDate.trim().length()<=0){
if (regDate == null || regDate.trim().length() <= 0)
{
errCode = "VTREGNULL";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}
else if(childNodeName.trim().equalsIgnoreCase("valid_upto")){
} else if (childNodeName.trim().equalsIgnoreCase("valid_upto"))
{
validUpto = this.genericUtility.getColumnValue("valid_upto", dom);
regDate = this.genericUtility.getColumnValue("reg_date", dom);
if(validUpto!=null){
if (validUpto != null)
{
Timestamp validUptoDate = Timestamp.valueOf(genericUtility.getValidDateString(validUpto,
genericUtility.getApplDateFormat(),genericUtility.getDBDateFormat()) + " 00:00:00.0");
genericUtility.getApplDateFormat(), genericUtility.getDBDateFormat()) + " 00:00:00.0");
Timestamp regDateNew = Timestamp.valueOf(genericUtility.getValidDateString(regDate,
genericUtility.getApplDateFormat(),genericUtility.getDBDateFormat()) + " 00:00:00.0");
genericUtility.getApplDateFormat(), genericUtility.getDBDateFormat()) + " 00:00:00.0");
if(validUptoDate.compareTo(regDateNew)<=0)
if (validUptoDate.compareTo(regDateNew) <= 0)
{
errCode = "VTVALREGDT";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}else{
} else
{
errCode = "VTVALNULL";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
......@@ -1321,50 +1501,53 @@ implements CustomerLocal, CustomerRemote {
}
}
valueXmlString.append("</Detail1>");
}
int errListSize = errList.size();
cnt = 0;
String errFldName = null;
if ((errList != null) && (errListSize > 0)) {
for (cnt = 0; cnt < errListSize; cnt++) {
if ((errList != null) && (errListSize > 0))
{
for (cnt = 0; cnt < errListSize; cnt++)
{
errCode = (String) errList.get(cnt);
errFldName = (String) errFields.get(cnt);
errString = getErrorString(errFldName, errCode, userId);
errorType = errorType(conn, errCode);
if (errString.length() > 0) {
String bifurErrString = errString.substring(
errString.indexOf("<Errors>") + 8,
errString.indexOf("<trace>"));
bifurErrString = bifurErrString
+ errString.substring(
errString.indexOf("</trace>") + 8,
errString.indexOf("</Errors>"));
if (errString.length() > 0)
{
String bifurErrString = errString.substring(errString.indexOf("<Errors>") + 8, errString.indexOf("<trace>"));
bifurErrString = bifurErrString + errString.substring(errString.indexOf("</trace>") + 8, errString.indexOf("</Errors>"));
errStringXml.append(bifurErrString);
errString = "";
}
if (errorType.equalsIgnoreCase("E")) {
if (errorType.equalsIgnoreCase("E"))
{
break;
}
}
errStringXml.append("</Errors> </Root> \r\n");
} else {
} else
{
errStringXml = new StringBuffer("");
}
} catch (Exception e) {
} catch (Exception e)
{
e.printStackTrace();
errString = e.getMessage();
throw new ITMException(e);
} finally {
try {
if (conn != null) {
if (rs != null) {
} finally
{
try
{
if (conn != null)
{
if (rs != null)
{
rs.close();
rs = null;
}
if (pstmt != null) {
if (pstmt != null)
{
pstmt.close();
pstmt = null;
}
......@@ -1372,7 +1555,8 @@ implements CustomerLocal, CustomerRemote {
conn.close();
}
conn = null;
} catch (Exception d) {
} catch (Exception d)
{
d.printStackTrace();
throw new ITMException(d);
}
......@@ -1381,42 +1565,40 @@ implements CustomerLocal, CustomerRemote {
return errString;
}
public String itemChanged(String xmlString, String xmlString1,
String xmlString2, String objContext, String currentColumn,
String editFlag, String xtraParams) throws RemoteException,
ITMException {
public String itemChanged(String xmlString, String xmlString1, String xmlString2, String objContext, String currentColumn, String editFlag, String xtraParams) throws RemoteException, ITMException
{
Document dom = null;
Document dom1 = null;
Document dom2 = null;
String valueXmlString = "";
try {
try
{
dom = parseString(xmlString);
dom1 = parseString(xmlString1);
if (xmlString2.trim().length() > 0) {
if (xmlString2.trim().length() > 0)
{
dom2 = parseString(xmlString2);
}
System.out.println("HELLO1 PRINT");
valueXmlString = itemChanged(dom, dom1, dom2, objContext,currentColumn, editFlag, xtraParams);
valueXmlString = itemChanged(dom, dom1, dom2, objContext, currentColumn, editFlag, xtraParams);
System.out.println("valueXmlString[" + valueXmlString + "]");
} catch (Exception e) {
System.out.println("Exception : [MiscVal][itemChanged( String, String )] :==>\n"+ e.getMessage());
} catch (Exception e)
{
System.out.println("Exception : [MiscVal][itemChanged( String, String )] :==>\n" + e.getMessage());
throw new ITMException(e);
}
System.out.println("VALUE HELLO PRINTA[" + valueXmlString + "]");
return valueXmlString;
}
public String itemChanged(Document dom, Document dom1, Document dom2,
String objContext, String currentColumn, String editFlag,
String xtraParams) throws RemoteException, ITMException {
System.out.println("sTART PRINT ");
public String itemChanged(Document dom, Document dom1, Document dom2, String objContext, String currentColumn, String editFlag, String xtraParams) throws RemoteException, ITMException
{
NodeList parentNodeList = null;
NodeList childNodeList = null;
Node parentNode = null;
Node childNode = null;
String childNodeName = null;
String sql = "",sql1 = "",sql2 = "";
String sql = "", sql1 = "", sql2 = "";
Connection conn = null;
PreparedStatement pstmt = null;
PreparedStatement pstmt1 = null;
......@@ -1424,19 +1606,18 @@ implements CustomerLocal, CustomerRemote {
ResultSet rs = null;
ResultSet rs1 = null;
ResultSet rs2 = null;
String resBKList = "",lsDescr = "",lsBKListed = "";
String lsNull = "",nullVarr="",ldDate="";
String custCodeBill="",custCode="",stanCode="",currCode="",countCode="";
String lsStateCode="",lsCity="",lsPin="";
String custName="",chqName="",terrCode="",terrDesc="",salesPers="",spName="",contactCode="",groupCode="";
String bankCode="",bankName="";
String channelPartner="";
String crTerm="",crDays="";
String rateRound="";
String name="", shName="", contPers="", contPfx="", addr1="", addr2="",addr3="", stateCode="",
tele1="", tele2="", tele3="",teleExt="", fax="", emailAddr="", ediAddr="";
String contPfx1="",contPers1="",Add1="",emailAddr1="",ediAddr1="",keyFlag="";
String regCode="",regDescr="",empCodeOrd="",empFname="",empLname="",empCodeOrd1="",deptCode="";
String resBKList = "", lsDescr = "", lsBKListed = "";
String lsNull = "", nullVarr = "", ldDate = "";
String custCodeBill = "", custCode = "", stanCode = "", currCode = "", countCode = "";
String lsStateCode = "", lsCity = "", lsPin = "";
String custName = "", chqName = "", terrCode = "", terrDesc = "", salesPers = "", spName = "", contactCode = "", groupCode = "";
String bankCode = "", bankName = "";
String channelPartner = "";
String crTerm = "", crDays = "";
String rateRound = "";
String name = "", shName = "", contPers = "", contPfx = "", addr1 = "", addr2 = "", addr3 = "", stateCode = "", tele1 = "", tele2 = "", tele3 = "", teleExt = "", fax = "", emailAddr = "", ediAddr = "";
String contPfx1 = "", contPers1 = "", Add1 = "", emailAddr1 = "", ediAddr1 = "", keyFlag = "";
String regCode = "", regDescr = "", empCodeOrd = "", empFname = "", empLname = "", empCodeOrd1 = "", deptCode = "";
int ctr = 0;
int currentFormNo = 0;
java.util.Date reqDate = null;
......@@ -1449,47 +1630,49 @@ implements CustomerLocal, CustomerRemote {
GenericUtility genericUtility = GenericUtility.getInstance();
ConnDriver connDriver = new ConnDriver();
try {
try
{
sdf = new SimpleDateFormat(genericUtility.getApplDateFormat());
conn = connDriver.getConnectDB("DriverITM");
conn.setAutoCommit(false);
connDriver = null;
this.finCommon = new FinCommon();
SimpleDateFormat simpleDateFormat = new SimpleDateFormat(
genericUtility.getApplDateFormat());
if ((objContext != null) && (objContext.trim().length() > 0)) {
SimpleDateFormat simpleDateFormat = new SimpleDateFormat(genericUtility.getApplDateFormat());
if ((objContext != null) && (objContext.trim().length() > 0))
{
currentFormNo = Integer.parseInt(objContext);
}
valueXmlString = new StringBuffer(
"<?xml version = \"1.0\"?> <Root> <header> <editFlag>");
valueXmlString = new StringBuffer("<?xml version = \"1.0\"?> <Root> <header> <editFlag>");
valueXmlString.append(editFlag).append("</editFlag> </header>");
switch (currentFormNo) {
switch (currentFormNo)
{
case 1:
parentNodeList = dom.getElementsByTagName("Detail1");
parentNode = parentNodeList.item(0);
childNodeList = parentNode.getChildNodes();
valueXmlString.append("<Detail1>");
childNodeListLength = childNodeList.getLength();
do {
do
{
childNode = childNodeList.item(ctr);
childNodeName = childNode.getNodeName();
if (childNodeName.equals(currentColumn)) {
if (childNodeName.equals(currentColumn))
{
childNode.getFirstChild();
}
ctr++;
} while ((ctr < childNodeListLength)&& (!childNodeName.equals(currentColumn)));
} while ((ctr < childNodeListLength) && (!childNodeName.equals(currentColumn)));
System.out.println("CURRENT COLUMN [" + currentColumn + "]");
if (currentColumn.trim().equalsIgnoreCase("itm_defaultedit")) {
if (currentColumn.trim().equalsIgnoreCase("itm_defaultedit"))
{
resBKList = checkNull(this.genericUtility.getColumnValue("reas_code__bklist", dom));
sql = "select descr from gencodes where fld_name = 'REAS_CODE__BKLIST' "
+ "and fld_value = ?";
sql = "select descr from gencodes where fld_name = 'REAS_CODE__BKLIST' " + "and fld_value = ?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, resBKList);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
lsDescr = checkNull(rs.getString("descr"));
}
rs.close();
......@@ -1499,23 +1682,23 @@ implements CustomerLocal, CustomerRemote {
valueXmlString.append("<bklist_reason ><![CDATA[" + lsDescr + "]]></bklist_reason>");
lsBKListed = checkNull(this.genericUtility.getColumnValue("black_listed", dom));
if (lsBKListed.equalsIgnoreCase("N")) {
if (lsBKListed.equalsIgnoreCase("N"))
{
valueXmlString.append("<reas_code__bklist protect = \"1\"><![CDATA[" + lsNull + "]]></reas_code__bklist>");
valueXmlString.append("<bklist_reason ><![CDATA[" + lsNull + "]]></bklist_reason>");
} else {
} else
{
valueXmlString.append("<reas_code__bklist><![CDATA[" + lsNull + "]]></reas_code__bklist>");
}
} else if (currentColumn.trim().equalsIgnoreCase("itm_default")) {
// valueXmlString.append("<emp_code__ord ><![CDATA[" + login_emp_code + "]]></emp_code__ord>");
// valueXmlString.append("<emp_code__ord1 ><![CDATA[" + login_emp_code + "]]></emp_code__ord1>");
} else if (currentColumn.trim().equalsIgnoreCase("itm_default"))
{
resBKList = checkNull(this.genericUtility.getColumnValue("reas_code__bklist", dom));
sql = "select descr from gencodes where fld_name = 'REAS_CODE__BKLIST' "
+ "and fld_value = ?";
sql = "select descr from gencodes where fld_name = 'REAS_CODE__BKLIST' " + "and fld_value = ?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, resBKList);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
lsDescr = checkNull(rs.getString("descr"));
}
rs.close();
......@@ -1526,21 +1709,24 @@ implements CustomerLocal, CustomerRemote {
valueXmlString.append("<bklist_reason ><![CDATA[" + lsDescr + "]]></bklist_reason>");
lsBKListed = checkNull(this.genericUtility.getColumnValue("black_listed", dom));
if (lsBKListed.equalsIgnoreCase("N")) {
if ("N".equalsIgnoreCase(lsBKListed))
{
valueXmlString.append("<reas_code__bklist protect = \"1\"><![CDATA[" + lsNull + "]]></reas_code__bklist>");
valueXmlString.append("<bklist_reason ><![CDATA[" + lsNull + "]]></bklist_reason>");
} else {
} else
{
valueXmlString.append("<reas_code__bklist><![CDATA[" + lsNull + "]]></reas_code__bklist>");
}
}else if (currentColumn.trim().equalsIgnoreCase("cust_code")) {
} else if (currentColumn.trim().equalsIgnoreCase("cust_code"))
{
custCode = checkNull(this.genericUtility.getColumnValue("cust_code", dom));
custCodeBill = checkNull(this.genericUtility.getColumnValue(
"cust_code__bil", dom));
// if(custCodeBill==null && custCodeBill.trim().length()<=0){
custCodeBill = checkNull(this.genericUtility.getColumnValue("cust_code__bil", dom));
// if(custCodeBill==null &&
// custCodeBill.trim().length()<=0){
valueXmlString.append("<cust_code__bil><![CDATA[" + custCode + "]]></cust_code__bil>");
valueXmlString.append("<group_code><![CDATA[" + custCode + "]]></group_code>");
// }
// }
} else if (currentColumn.trim().equalsIgnoreCase("stan_code"))
{
......@@ -1549,7 +1735,8 @@ implements CustomerLocal, CustomerRemote {
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, stanCode);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
lsStateCode = checkNull(rs.getString("state_code"));
lsCity = checkNull(rs.getString("city"));
lsPin = checkNull(rs.getString("pin"));
......@@ -1559,12 +1746,14 @@ implements CustomerLocal, CustomerRemote {
pstmt.close();
pstmt = null;
if(lsStateCode!=null && lsStateCode.trim().length()>0){
if (lsStateCode != null && lsStateCode.trim().length() > 0)
{
sql1 = "select count_code from state where state_code =?";
pstmt1 = conn.prepareStatement(sql1);
pstmt1.setString(1, lsStateCode);
rs1 = pstmt1.executeQuery();
if (rs1.next()) {
if (rs1.next())
{
countCode = checkNull(rs1.getString("count_code"));
}
rs1.close();
......@@ -1573,12 +1762,14 @@ implements CustomerLocal, CustomerRemote {
pstmt1 = null;
}
if(countCode!=null && countCode.trim().length()>0){
if (countCode != null && countCode.trim().length() > 0)
{
sql2 = "select curr_code from country where count_code =?";
pstmt2 = conn.prepareStatement(sql2);
pstmt2.setString(1, countCode);
rs2 = pstmt2.executeQuery();
if (rs2.next()) {
if (rs2.next())
{
currCode = checkNull(rs2.getString("curr_code"));
}
rs2.close();
......@@ -1590,21 +1781,26 @@ implements CustomerLocal, CustomerRemote {
valueXmlString.append("<state_code><![CDATA[" + lsStateCode + "]]></state_code>");
valueXmlString.append("<count_code><![CDATA[" + countCode + "]]></count_code>");
valueXmlString.append("<curr_code><![CDATA[" + currCode + "]]></curr_code>");
}else if(currentColumn.trim().equalsIgnoreCase("cust_name")){
} else if (currentColumn.trim().equalsIgnoreCase("cust_name"))
{
custName = checkNull(this.genericUtility.getColumnValue("cust_name", dom));
chqName=checkNull(this.genericUtility.getColumnValue("chq_name", dom));
if(chqName==null || chqName.trim().length()<=0){
chqName = checkNull(this.genericUtility.getColumnValue("chq_name", dom));
if (chqName == null || chqName.trim().length() <= 0)
{
valueXmlString.append("<chq_name><![CDATA[" + custName + "]]></chq_name>");
}
}else if(currentColumn.trim().equalsIgnoreCase("terr_code")){
} else if (currentColumn.trim().equalsIgnoreCase("terr_code"))
{
terrCode = checkNull(this.genericUtility.getColumnValue("terr_code", dom));
if(terrCode!=null && terrCode.trim().length()>0){
if (terrCode != null && terrCode.trim().length() > 0)
{
sql = "select descr from territory where terr_code =?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, terrCode);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
terrDesc = checkNull(rs.getString("descr"));
}
rs.close();
......@@ -1614,13 +1810,15 @@ implements CustomerLocal, CustomerRemote {
}
valueXmlString.append("<territory_descr><![CDATA[" + terrDesc + "]]></territory_descr>");
}else if(currentColumn.trim().equalsIgnoreCase("sales_pers")){
} else if (currentColumn.trim().equalsIgnoreCase("sales_pers"))
{
salesPers = checkNull(this.genericUtility.getColumnValue("sales_pers", dom));
sql = "select sp_name from sales_pers where sales_pers=?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, salesPers);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
spName = checkNull(rs.getString("sp_name"));
}
rs.close();
......@@ -1628,16 +1826,16 @@ implements CustomerLocal, CustomerRemote {
pstmt.close();
pstmt = null;
valueXmlString.append("<sp_name><![CDATA[" + spName + "]]></sp_name>");
}else if(currentColumn.trim().equalsIgnoreCase("contact_code")){
} else if (currentColumn.trim().equalsIgnoreCase("contact_code"))
{
contactCode = checkNull(this.genericUtility.getColumnValue("contact_code", dom));
sql = "select name, sh_name, cont_pers, cont_pfx, addr1, addr2,addr3, city, pin, state_code,"
+ " count_code, tele1, tele2, tele3,tele_ext, fax, email_addr, edi_addr"
+ " from contact where contact_code = ?";
sql = "select name, sh_name, cont_pers, cont_pfx, addr1, addr2,addr3, city, pin, state_code," + " count_code, tele1, tele2, tele3,tele_ext, fax, email_addr, edi_addr" + " from contact where contact_code = ?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, contactCode);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
name = checkNull(rs.getString("name"));
shName = checkNull(rs.getString("sh_name"));
contPers = checkNull(rs.getString("cont_pers"));
......@@ -1663,29 +1861,29 @@ implements CustomerLocal, CustomerRemote {
pstmt = null;
custName = checkNull(this.genericUtility.getColumnValue("cust_name", dom));
if(custName==null || custName.trim().length()<=0){
valueXmlString.append("<cust_name>")
.append("<![CDATA[" +name+ "]]>")
.append("</cust_name>");
if (custName == null || custName.trim().length() <= 0)
{
valueXmlString.append("<cust_name>").append("<![CDATA[" + name + "]]>").append("</cust_name>");
valueXmlString.append("<chq_name><![CDATA[" + name + "]]></chq_name>");
valueXmlString.append("<sh_name><![CDATA[" + shName + "]]></sh_name>");
}
contPfx1 = checkNull(this.genericUtility.getColumnValue("cont_pfx", dom));
if(contPfx1==null || contPfx1.trim().length()<=0){
if (contPfx1 == null || contPfx1.trim().length() <= 0)
{
valueXmlString.append("<cont_pfx><![CDATA[" + contPfx + "]]></cont_pfx>");
}
contPers1 = checkNull(this.genericUtility.getColumnValue("cont_pers", dom));
if(contPers1==null || contPers1.trim().length()<=0){
if (contPers1 == null || contPers1.trim().length() <= 0)
{
valueXmlString.append("<cont_pers><![CDATA[" + contPers + "]]></cont_pers>");
}
Add1 = checkNull(this.genericUtility.getColumnValue("addr1", dom));
if(Add1==null || Add1.trim().length()<=0){
if (Add1 == null || Add1.trim().length() <= 0)
{
valueXmlString.append("<addr1><![CDATA[" + addr1 + "]]></addr1>");
valueXmlString.append("<addr2><![CDATA[" + addr2 + "]]></addr2>");
valueXmlString.append("<addr3><![CDATA[" + addr3 + "]]></addr3>");
......@@ -1705,12 +1903,14 @@ implements CustomerLocal, CustomerRemote {
}
emailAddr1 = checkNull(this.genericUtility.getColumnValue("email_addr", dom));
if(emailAddr1==null || emailAddr1.trim().length()<=0){
if (emailAddr1 == null || emailAddr1.trim().length() <= 0)
{
valueXmlString.append("<email_addr ><![CDATA[" + emailAddr + "]]></email_addr>");
}
ediAddr1 = checkNull(this.genericUtility.getColumnValue("edi_addr", dom));
if(ediAddr1==null || ediAddr1.trim().length()<=0){
if (ediAddr1 == null || ediAddr1.trim().length() <= 0)
{
valueXmlString.append("<edi_addr ><![CDATA[" + ediAddr + "]]></edi_addr>");
}
......@@ -1718,7 +1918,8 @@ implements CustomerLocal, CustomerRemote {
sql2 = "select key_flag from transetup where tran_window = 'w_customer'";
pstmt2 = conn.prepareStatement(sql2);
rs2 = pstmt2.executeQuery();
if (rs2.next()) {
if (rs2.next())
{
keyFlag = checkNull(rs2.getString("key_flag"));
}
rs2.close();
......@@ -1726,13 +1927,15 @@ implements CustomerLocal, CustomerRemote {
pstmt2.close();
pstmt2 = null;
if(custCode==null && !(keyFlag.equalsIgnoreCase("A"))){
if (custCode == null && !(keyFlag.equalsIgnoreCase("A")))
{
contactCode = checkNull(this.genericUtility.getColumnValue("contact_code", dom));
valueXmlString.append("<cust_code ><![CDATA[" + contactCode + "]]></cust_code>");
}
custCodeBill = checkNull(this.genericUtility.getColumnValue("cust_code__bil", dom));
if(custCodeBill==null || custCodeBill.trim().length()<=0){
if (custCodeBill == null || custCodeBill.trim().length() <= 0)
{
contactCode = checkNull(this.genericUtility.getColumnValue("contact_code", dom));
valueXmlString.append("<cust_code__bil ><![CDATA[" + contactCode + "]]></cust_code__bil>");
......@@ -1740,7 +1943,8 @@ implements CustomerLocal, CustomerRemote {
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, contactCode);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
custName = checkNull(rs.getString("cust_name"));
}
rs.close();
......@@ -1748,14 +1952,15 @@ implements CustomerLocal, CustomerRemote {
pstmt.close();
pstmt = null;
if(custName!=null){
if (custName != null)
{
valueXmlString.append("<customer_cust_name_1 ><![CDATA[" + custName + "]]></customer_cust_name_1>");
}
}
groupCode = checkNull(this.genericUtility.getColumnValue(
"group_code", dom));
if(groupCode==null || groupCode.trim().length()<=0){
groupCode = checkNull(this.genericUtility.getColumnValue("group_code", dom));
if (groupCode == null || groupCode.trim().length() <= 0)
{
contactCode = checkNull(this.genericUtility.getColumnValue("contact_code", dom));
valueXmlString.append("<group_code ><![CDATA[" + contactCode + "]]></group_code>");
......@@ -1763,7 +1968,8 @@ implements CustomerLocal, CustomerRemote {
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, contactCode);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
custName = checkNull(rs.getString("cust_name"));
}
rs.close();
......@@ -1771,18 +1977,21 @@ implements CustomerLocal, CustomerRemote {
pstmt.close();
pstmt = null;
if(custName!=null){
if (custName != null)
{
valueXmlString.append("<customer_cust_name ><![CDATA[" + custName + "]]></customer_cust_name>");
}
}
}else if(currentColumn.trim().equalsIgnoreCase("bank_code")){
} else if (currentColumn.trim().equalsIgnoreCase("bank_code"))
{
bankCode = checkNull(this.genericUtility.getColumnValue("bank_code", dom));
sql = "select bank_name from bank where bank_code=?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, bankCode);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
bankName = checkNull(rs.getString("bank_name"));
}
rs.close();
......@@ -1791,38 +2000,46 @@ implements CustomerLocal, CustomerRemote {
pstmt = null;
valueXmlString.append("<bank_name ><![CDATA[" + bankName + "]]></bank_name>");
}else if(currentColumn.trim().equalsIgnoreCase("channel_partner")){
} else if (currentColumn.trim().equalsIgnoreCase("channel_partner"))
{
channelPartner = checkNull(this.genericUtility.getColumnValue("channel_partner", dom));
if(channelPartner.equalsIgnoreCase("Y")){
if (channelPartner.equalsIgnoreCase("Y"))
{
valueXmlString.append("<site_code protect = \"0\"><![CDATA[]]></site_code>");
valueXmlString.append("<fin_link protect = \"0\"><![CDATA[]]></fin_link>");
valueXmlString.append("<dis_link protect = \"0\"><![CDATA[]]></dis_link>");
}else{
} else
{
valueXmlString.append("<site_code protect = \"1\"><![CDATA[" + nullVarr + "]]></site_code>");
valueXmlString.append("<fin_link protect = \"1\"><![CDATA[" + nullVarr + "]]></fin_link>");
valueXmlString.append("<dis_link protect = \"1\"><![CDATA[" + nullVarr + "]]></dis_link>");
}
}else if(currentColumn.trim().equalsIgnoreCase("black_listed")){
} else if (currentColumn.trim().equalsIgnoreCase("black_listed"))
{
lsBKListed = checkNull(this.genericUtility.getColumnValue("black_listed", dom));
System.out.println("black_listed :- "+lsBKListed);
if(lsBKListed.equalsIgnoreCase("N")){
System.out.println("black_listed :- " + lsBKListed);
if (lsBKListed.equalsIgnoreCase("N"))
{
valueXmlString.append("<black_listed_date protect = \"1\"><![CDATA[" + ldDate + "]]></black_listed_date>");
valueXmlString.append("<reas_code__bklist protect = \"1\"><![CDATA[" + lsNull + "]]></reas_code__bklist>");
valueXmlString.append("<bklist_reason protect = \"1\"><![CDATA[" + lsNull + "]]></bklist_reason>");
}else{
} else
{
valueXmlString.append("<black_listed_date protect = \"0\"><![CDATA[]]></black_listed_date>");
valueXmlString.append("<reas_code__bklist protect = \"0\"><![CDATA[]]></reas_code__bklist>");
}
}else if(currentColumn.trim().equalsIgnoreCase("reas_code__bklist")){
} else if (currentColumn.trim().equalsIgnoreCase("reas_code__bklist"))
{
resBKList = checkNull(this.genericUtility.getColumnValue("reas_code__bklist", dom));
sql = "select descr from gencodes where fld_name = 'REAS_CODE__BKLIST' and fld_value =?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, resBKList);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
lsDescr = checkNull(rs.getString("descr"));
}
rs.close();
......@@ -1830,17 +2047,17 @@ implements CustomerLocal, CustomerRemote {
pstmt.close();
pstmt = null;
valueXmlString.append("<bklist_reason >")
.append("<![CDATA[" + lsDescr + "]]>")
.append("</bklist_reason>");
}else if(currentColumn.trim().equalsIgnoreCase("cr_term")){
valueXmlString.append("<bklist_reason >").append("<![CDATA[" + lsDescr + "]]>").append("</bklist_reason>");
} else if (currentColumn.trim().equalsIgnoreCase("cr_term"))
{
crTerm = checkNull(this.genericUtility.getColumnValue("cr_term", dom));
sql = "select cr_days from crterm where cr_term =?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, crTerm);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
crDays = checkNull(rs.getString("cr_days"));
}
rs.close();
......@@ -1849,22 +2066,27 @@ implements CustomerLocal, CustomerRemote {
pstmt = null;
valueXmlString.append("<credit_prd ><![CDATA[" + crDays + "]]></credit_prd>");
}else if(currentColumn.trim().equalsIgnoreCase("rate_round")){
} else if (currentColumn.trim().equalsIgnoreCase("rate_round"))
{
rateRound = checkNull(this.genericUtility.getColumnValue("rate_round", dom));
if(rateRound.equalsIgnoreCase("N")){
if (rateRound.equalsIgnoreCase("N"))
{
valueXmlString.append("<rate_round_to protect = \"1\"><![CDATA[]]></rate_round_to>");
}else{
} else
{
valueXmlString.append("<rate_round_to protect = \"0\"><![CDATA[]]></rate_round_to>");
}
}else if(currentColumn.trim().equalsIgnoreCase("group_code")){
} else if (currentColumn.trim().equalsIgnoreCase("group_code"))
{
groupCode = checkNull(this.genericUtility.getColumnValue("group_code", dom));
sql = "select cust_name from customer where cust_code =?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, groupCode);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
custName = checkNull(rs.getString("cust_name"));
}
rs.close();
......@@ -1873,14 +2095,16 @@ implements CustomerLocal, CustomerRemote {
pstmt = null;
valueXmlString.append("<customer_cust_name ><![CDATA[" + custName + "]]></customer_cust_name>");
}else if(currentColumn.trim().equalsIgnoreCase("cust_code__bil")){
} else if (currentColumn.trim().equalsIgnoreCase("cust_code__bil"))
{
custCodeBill = checkNull(this.genericUtility.getColumnValue("cust_code__bil", dom));
sql = "select cust_name from customer where cust_code =?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, custCodeBill);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
custName = checkNull(rs.getString("cust_name"));
}
rs.close();
......@@ -1888,16 +2112,18 @@ implements CustomerLocal, CustomerRemote {
pstmt.close();
pstmt = null;
valueXmlString.append("<customer_cust_name_1 ><![CDATA[" + custName + "]]></customer_cust_name_1>");
}else if(currentColumn.trim().equalsIgnoreCase("emp_code__ord")){
} else if (currentColumn.trim().equalsIgnoreCase("emp_code__ord"))
{
empCodeOrd = checkNull(this.genericUtility.getColumnValue("emp_code__ord", dom));
if(empCodeOrd!=null){
if (empCodeOrd != null)
{
sql = "select emp_fname,emp_lname,dept_code from employee where emp_code=?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, empCodeOrd);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
empFname = checkNull(rs.getString("emp_fname"));
empLname = checkNull(rs.getString("emp_lname"));
deptCode = checkNull(rs.getString("dept_code"));
......@@ -1911,14 +2137,17 @@ implements CustomerLocal, CustomerRemote {
valueXmlString.append("<emp_lname ><![CDATA[" + empLname + "]]></emp_lname>");
valueXmlString.append("<dept_code ><![CDATA[" + deptCode + "]]></dept_code>");
}
}else if(currentColumn.trim().equalsIgnoreCase("emp_code__ord1")){
} else if (currentColumn.trim().equalsIgnoreCase("emp_code__ord1"))
{
empCodeOrd1 = checkNull(this.genericUtility.getColumnValue("emp_code__ord1", dom));
if(empCodeOrd1!=null){
if (empCodeOrd1 != null)
{
sql = "select emp_fname,emp_lname,dept_code from employee where emp_code=?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, empCodeOrd1);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
empFname = checkNull(rs.getString("emp_fname"));
empLname = checkNull(rs.getString("emp_lname"));
deptCode = checkNull(rs.getString("dept_code"));
......@@ -1942,27 +2171,29 @@ implements CustomerLocal, CustomerRemote {
valueXmlString.append("<Detail2>");
childNodeListLength = childNodeList.getLength();
do {
do
{
childNode = childNodeList.item(ctr);
childNodeName = childNode.getNodeName();
if (childNodeName.equals(currentColumn)) {
if (childNodeName.equals(currentColumn))
{
childNode.getFirstChild();
}
ctr++;
} while ((ctr < childNodeListLength)
&& (!childNodeName.equals(currentColumn)));
} while ((ctr < childNodeListLength) && (!childNodeName.equals(currentColumn)));
System.out.println("CURRENT COLUMN [" + currentColumn + "]");
if (currentColumn.trim().equalsIgnoreCase("reg_code")) {
if (currentColumn.trim().equalsIgnoreCase("reg_code"))
{
regCode = checkNull(this.genericUtility.getColumnValue("reg_code", dom));
sql = "select descr from reg_requirements where reg_code=?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, regCode);
rs = pstmt.executeQuery();
if (rs.next()) {
if (rs.next())
{
regDescr = checkNull(rs.getString("descr"));
}
rs.close();
......@@ -1970,21 +2201,22 @@ implements CustomerLocal, CustomerRemote {
pstmt.close();
pstmt = null;
System.out.println("Registration descr from field value $$$$$$$$$$$$$$$444444444444444444444:-["+regDescr+"]");
valueXmlString.append("<descr ><![CDATA[" + regDescr + "]]></descr>");
}
valueXmlString.append("</Detail2>");
}
valueXmlString.append("</Root>");
} catch (Exception e) {
} catch (Exception e)
{
e.printStackTrace();
System.out.println("Exception ::" + e.getMessage());
throw new ITMException(e);
} finally {
try {
if (conn != null) {
} finally
{
try
{
if (conn != null)
{
if (pstmt != null)
pstmt.close();
if (rs != null)
......@@ -1994,7 +2226,8 @@ implements CustomerLocal, CustomerRemote {
conn.close();
conn = null;
}
} catch (Exception d) {
} catch (Exception d)
{
d.printStackTrace();
throw new ITMException(d);
}
......@@ -2002,68 +2235,83 @@ implements CustomerLocal, CustomerRemote {
return valueXmlString.toString();
}
private String checkNull(String str) {
if (str == null) {
private String checkNull(String str)
{
if (str == null)
{
return "";
} else {
} else
{
return str;
}
}
private double checkDoubleNull(String str) {
if (str == null || str.trim().length() == 0) {
private double checkDoubleNull(String str)
{
if (str == null || str.trim().length() == 0)
{
return 0.0;
} else {
} else
{
return Double.parseDouble(str);
}
}
private String errorType(Connection conn, String errorCode)
throws ITMException {
private String errorType(Connection conn, String errorCode) throws ITMException
{
String msgType = "";
PreparedStatement pstmt = null;
ResultSet rs = null;
try {
try
{
String sql = "SELECT MSG_TYPE FROM MESSAGES WHERE MSG_NO = ?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, errorCode);
rs = pstmt.executeQuery();
while (rs.next()) {
while (rs.next())
{
msgType = rs.getString("MSG_TYPE");
}
} catch (Exception ex) {
} catch (Exception ex)
{
ex.printStackTrace();
try {
if (rs != null) {
try
{
if (rs != null)
{
rs.close();
rs = null;
}
if (pstmt != null) {
if (pstmt != null)
{
pstmt.close();
pstmt = null;
}
} catch (Exception e) {
} catch (Exception e)
{
e.printStackTrace();
throw new ITMException(e);
}
} finally {
try {
if (rs != null) {
} finally
{
try
{
if (rs != null)
{
rs.close();
rs = null;
}
if (pstmt != null) {
if (pstmt != null)
{
pstmt.close();
pstmt = null;
}
} catch (Exception e) {
} catch (Exception e)
{
e.printStackTrace();
throw new ITMException(e);
}
}
return msgType;
}
}
/********************************************************
Title : BillofQuantityICLocal
Date : 20/09/2012
Developer: Akhilesh Sikarwar
Title : CustomerLocal
Date : 20/10/14
Developer: Vallabh Kadam
********************************************************/
package ibase.webitm.ejb.dis;
......
/********************************************************
Title : BillofQuantityICRemote
Date : 22/09/2012
Developer: Akhilesh Sikarwar
Title : CustomerRemote
Date : 20/10/14
Developer: Vallabh Kadam
********************************************************/
......
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