Commit 51ce93bd authored by caluka's avatar caluka

Customer code is check in validatorEJB code


git-svn-id: http://15.206.35.175/svn/proteus/business-java/trunk@98657 ce508802-f39f-4f6c-b175-0d175dae99d5
parent 1e735ffc
...@@ -8,6 +8,7 @@ package ibase.webitm.ejb.dis; ...@@ -8,6 +8,7 @@ package ibase.webitm.ejb.dis;
import ibase.system.config.ConnDriver; import ibase.system.config.ConnDriver;
import ibase.webitm.ejb.ValidatorEJB; import ibase.webitm.ejb.ValidatorEJB;
import ibase.webitm.ejb.fin.FinCommon;
import ibase.webitm.ejb.mfg.MfgCommon; import ibase.webitm.ejb.mfg.MfgCommon;
import ibase.webitm.utility.ITMException; import ibase.webitm.utility.ITMException;
...@@ -34,6 +35,8 @@ import javax.ejb.Stateless; ...@@ -34,6 +35,8 @@ import javax.ejb.Stateless;
public class POBWizIC extends ValidatorEJB implements POBWizICLocal, POBWizICRemote public class POBWizIC extends ValidatorEJB implements POBWizICLocal, POBWizICRemote
{ {
E12GenericUtility genericUtility = new E12GenericUtility(); E12GenericUtility genericUtility = new E12GenericUtility();
FinCommon finCommon = null;
ValidatorEJB valEjb = null;
public static String staticSiteCode=""; public static String staticSiteCode="";
public static String staticCustCode=""; public static String staticCustCode="";
...@@ -116,6 +119,8 @@ public class POBWizIC extends ValidatorEJB implements POBWizICLocal, POBWizICRem ...@@ -116,6 +119,8 @@ public class POBWizIC extends ValidatorEJB implements POBWizICLocal, POBWizICRem
userId = getValueFromXTRA_PARAMS(xtraParams, "loginCode"); userId = getValueFromXTRA_PARAMS(xtraParams, "loginCode");
loginEmpCode = genericUtility.getValueFromXTRA_PARAMS(xtraParams, "loginEmpCode"); loginEmpCode = genericUtility.getValueFromXTRA_PARAMS(xtraParams, "loginEmpCode");
DistCommon distCommon = new DistCommon(); DistCommon distCommon = new DistCommon();
finCommon = new FinCommon();
valEjb =new ValidatorEJB();
if (objContext != null && objContext.trim().length() > 0) if (objContext != null && objContext.trim().length() > 0)
{ {
currentFormNo = Integer.parseInt(objContext); currentFormNo = Integer.parseInt(objContext);
...@@ -234,6 +239,16 @@ public class POBWizIC extends ValidatorEJB implements POBWizICLocal, POBWizICRem ...@@ -234,6 +239,16 @@ public class POBWizIC extends ValidatorEJB implements POBWizICLocal, POBWizICRem
errList.add(errCode); errList.add(errCode);
errFields.add(childNodeName.toLowerCase()); errFields.add(childNodeName.toLowerCase());
} }
else
{
errCode = valEjb.isCustomer(siteCode, custCode, "", conn);
System.out.println("errCode>>>>>>>>"+errCode);
if (errCode != null && errCode.trim().length() > 0 )
{
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}
} }
} else } else
{ {
...@@ -1405,8 +1420,8 @@ public class POBWizIC extends ValidatorEJB implements POBWizICLocal, POBWizICRem ...@@ -1405,8 +1420,8 @@ public class POBWizIC extends ValidatorEJB implements POBWizICLocal, POBWizICRem
valueXmlString.append("<item_code>").append("").append("</item_code>\r\n"); valueXmlString.append("<item_code>").append("").append("</item_code>\r\n");
valueXmlString.append("<descr>").append("").append("</descr>\r\n"); valueXmlString.append("<descr>").append("").append("</descr>\r\n");
valueXmlString.append("<unit>").append("").append("</unit>\r\n"); valueXmlString.append("<unit>").append("").append("</unit>\r\n");
valueXmlString.append("<quantity>").append("").append("</quantity>\r\n"); valueXmlString.append("<quantity>").append("0.0").append("</quantity>\r\n");
valueXmlString.append("<free_qty>").append("").append("</free_qty>\r\n"); valueXmlString.append("<free_qty>").append("0.0").append("</free_qty>\r\n");
valueXmlString.append("<rate>").append("0.0").append("</rate>\r\n"); valueXmlString.append("<rate>").append("0.0").append("</rate>\r\n");
valueXmlString.append("<discount>").append("").append("</discount>\r\n"); valueXmlString.append("<discount>").append("").append("</discount>\r\n");
valueXmlString.append("<tot_qty>").append("0.0").append("</tot_qty>\r\n"); valueXmlString.append("<tot_qty>").append("0.0").append("</tot_qty>\r\n");
...@@ -1434,8 +1449,8 @@ public class POBWizIC extends ValidatorEJB implements POBWizICLocal, POBWizICRem ...@@ -1434,8 +1449,8 @@ public class POBWizIC extends ValidatorEJB implements POBWizICLocal, POBWizICRem
valueXmlString.append("<item_code>").append("").append("</item_code>\r\n"); valueXmlString.append("<item_code>").append("").append("</item_code>\r\n");
valueXmlString.append("<descr>").append("").append("</descr>\r\n"); valueXmlString.append("<descr>").append("").append("</descr>\r\n");
valueXmlString.append("<unit>").append("").append("</unit>\r\n"); valueXmlString.append("<unit>").append("").append("</unit>\r\n");
valueXmlString.append("<quantity>").append("").append("</quantity>\r\n"); valueXmlString.append("<quantity>").append("0.0").append("</quantity>\r\n");
valueXmlString.append("<free_qty>").append("").append("</free_qty>\r\n"); valueXmlString.append("<free_qty>").append("0.0").append("</free_qty>\r\n");
valueXmlString.append("<rate>").append("0.0").append("</rate>\r\n"); valueXmlString.append("<rate>").append("0.0").append("</rate>\r\n");
valueXmlString.append("<discount>").append("").append("</discount>\r\n"); valueXmlString.append("<discount>").append("").append("</discount>\r\n");
valueXmlString.append("<tot_qty>").append("0.0").append("</tot_qty>\r\n"); valueXmlString.append("<tot_qty>").append("0.0").append("</tot_qty>\r\n");
...@@ -1523,7 +1538,7 @@ public class POBWizIC extends ValidatorEJB implements POBWizICLocal, POBWizICRem ...@@ -1523,7 +1538,7 @@ public class POBWizIC extends ValidatorEJB implements POBWizICLocal, POBWizICRem
{ {
valueXmlString.append("<free_qty>").append("").append("</free_qty>\r\n"); valueXmlString.append("<free_qty>").append("").append("</free_qty>\r\n");
} }
valueXmlString.append("<discount>").append("<![CDATA[" + discount + "]]>").append("</discount>\r\n"); //valueXmlString.append("<discount>").append("<![CDATA[" + discount + "]]>").append("</discount>\r\n");
valueXmlString.append("<discount>").append("<![CDATA[" + getRequiredDecimal(discount, 3) + "]]>").append("</discount>\r\n"); valueXmlString.append("<discount>").append("<![CDATA[" + getRequiredDecimal(discount, 3) + "]]>").append("</discount>\r\n");
valueXmlString.append("<tot_qty>").append("<![CDATA[" + getRequiredDecimal((quantity + freeQty), 3) + "]]>").append("</tot_qty>\r\n"); valueXmlString.append("<tot_qty>").append("<![CDATA[" + getRequiredDecimal((quantity + freeQty), 3) + "]]>").append("</tot_qty>\r\n");
if (pickRate < 0) if (pickRate < 0)
......
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