Commit 32af2052 authored by pshinde's avatar pshinde

Source code for Itemchanged and validation and post save for Period Table Generation


git-svn-id: http://15.206.35.175/svn/proteus/business-java/trunk@100050 ce508802-f39f-4f6c-b175-0d175dae99d5
parent 4f5c363d
/******************************************************** /********************************************************
Title : PrdTableGenICLocal [D15JSUN001] Title : BankGauranteeLocal [F15DSUN018]
Developer: Priyanka Shinde. Date : 22/JUL/15
Developer: Pankaj R.
********************************************************/ ********************************************************/
package ibase.webitm.ejb.dis; package ibase.webitm.ejb.dis;
......
/******************************************************** /********************************************************
Title : PrdTableGenICRemote [D15JSUN001] Title : BankGauranteeRemote [F15DSUN018]
Developer: Priyanka Shinde. Date : 22/JUL/15
Developer: Pankaj R.
********************************************************/ ********************************************************/
package ibase.webitm.ejb.dis; package ibase.webitm.ejb.dis;
......
/********************************************************
Title : PrdTableGenPostSave [D15JSUN001]
Developer: Priyanka Shinde.
********************************************************/
package ibase.webitm.ejb.dis; package ibase.webitm.ejb.dis;
import org.w3c.dom.*; import org.w3c.dom.*;
...@@ -66,6 +60,7 @@ public class PrdTableGenPostSave extends ValidatorEJB implements PrdTableGenPost ...@@ -66,6 +60,7 @@ public class PrdTableGenPostSave extends ValidatorEJB implements PrdTableGenPost
String prdCode="",prdTblNo="",frDate="",toDate="",prdClose=""; String prdCode="",prdTblNo="",frDate="",toDate="",prdClose="";
String chgUser="",chgTerm=""; String chgUser="",chgTerm="";
String errString = ""; String errString = "";
String selectedValue = "",status="",isChanged="";
int cnt=0,updateCount=0,detCnt=0; int cnt=0,updateCount=0,detCnt=0;
ITMDBAccessEJB itmDBAccessEJB = null; ITMDBAccessEJB itmDBAccessEJB = null;
boolean value=false; boolean value=false;
...@@ -91,14 +86,35 @@ public class PrdTableGenPostSave extends ValidatorEJB implements PrdTableGenPost ...@@ -91,14 +86,35 @@ public class PrdTableGenPostSave extends ValidatorEJB implements PrdTableGenPost
Node detailListNode = hdrDommList.item(dtlCtr); Node detailListNode = hdrDommList.item(dtlCtr);
NodeList detail2List= detailListNode.getChildNodes(); NodeList detail2List= detailListNode.getChildNodes();
// System.out.println("@@@@@@@@@node name[" + detailListNode.getNodeName()+"]"); // System.out.println("@@@@@@@@@node name[" + detailListNode.getNodeName()+"]");
System.out.println("detailListNode===="+detailListNode);
if("Detail2".equalsIgnoreCase(detailListNode.getNodeName())) if("Detail2".equalsIgnoreCase(detailListNode.getNodeName()))
{ {
System.out.println("detail2List===="+detail2List);
// System.out.println("@@@@inside detail4----------------"); // System.out.println("@@@@inside detail4----------------");
for (int cntr = 0; cntr < detail2List.getLength(); cntr++) for (int cntr = 0; cntr < detail2List.getLength(); cntr++)
{ {
Node detail2Node = detail2List.item(cntr); Node detail2Node = detail2List.item(cntr);
System.out.println("detail2Node===="+detail2Node);
if(detail2Node != null && detail2Node.getNodeName().equalsIgnoreCase("attribute"))
{
System.out.println("Check for selected Value######");
selectedValue = detail2Node.getAttributes().getNamedItem("selected").getNodeValue();
System.out.println("selectedValue=========="+selectedValue);
System.out.println("Check for STATUS Value######");
status = detail2Node.getAttributes().getNamedItem("status").getNodeValue();
System.out.println("status=========="+status);
System.out.println("Check for IS_CHANGE Value######");
isChanged = detail2Node.getAttributes().getNamedItem("IS_CHANGE").getNodeValue();
System.out.println("isChanged=========="+isChanged);
}
if("prd_code".equalsIgnoreCase( detail2Node.getNodeName())) if("prd_code".equalsIgnoreCase( detail2Node.getNodeName()))
{ {
if( detail2List.item(cntr).getFirstChild() != null) if( detail2List.item(cntr).getFirstChild() != null)
...@@ -165,6 +181,13 @@ public class PrdTableGenPostSave extends ValidatorEJB implements PrdTableGenPost ...@@ -165,6 +181,13 @@ public class PrdTableGenPostSave extends ValidatorEJB implements PrdTableGenPost
System.out.println("@@@@ctr["+dtlCtr+"]Period code["+prdCode+"]-Period table Code["+prdTblNo+"]-from date["+frDate+"]To Date["+toDate+"]period closed["+prdClose+"]@@@"); System.out.println("@@@@ctr["+dtlCtr+"]Period code["+prdCode+"]-Period table Code["+prdTblNo+"]-from date["+frDate+"]To Date["+toDate+"]period closed["+prdClose+"]@@@");
if("N".equalsIgnoreCase(status))
{
System.out.println("selected Value for record===="+selectedValue);
sql="select count(1) from period_tbl where prd_code= ? and prd_tblno= ?"; sql="select count(1) from period_tbl where prd_code= ? and prd_tblno= ?";
pstmt=conn.prepareStatement(sql); pstmt=conn.prepareStatement(sql);
pstmt.setString(1, prdCode); pstmt.setString(1, prdCode);
...@@ -219,11 +242,13 @@ public class PrdTableGenPostSave extends ValidatorEJB implements PrdTableGenPost ...@@ -219,11 +242,13 @@ public class PrdTableGenPostSave extends ValidatorEJB implements PrdTableGenPost
pstmt.close(); pstmt.close();
pstmt = null; pstmt = null;
} }
if(detCnt>0 ||updateCount>0) if(detCnt>0 ||updateCount>0)
{ {
System.out.println(">>The selected transaction is confirmed"); System.out.println(">>The selected transaction is confirmed");
errString = itmDBAccessEJB.getErrorString("","VTCONSUCF","","",conn); errString = itmDBAccessEJB.getErrorString("","VTCONSUCF","","",conn);
} }
}//end
} }
......
/********************************************************
Title : PrdTableGenPostSaveLocal [D15JSUN001]
Developer: Priyanka Shinde.
********************************************************/
package ibase.webitm.ejb.dis; package ibase.webitm.ejb.dis;
import java.rmi.RemoteException; import java.rmi.RemoteException;
import ibase.webitm.ejb.ValidatorLocal; import ibase.webitm.ejb.ValidatorLocal;
......
/********************************************************
Title : PrdTableGenPostSaveRemote [D15JSUN001]
Developer: Priyanka Shinde.
********************************************************/
package ibase.webitm.ejb.dis; package ibase.webitm.ejb.dis;
import java.rmi.RemoteException; import java.rmi.RemoteException;
import ibase.webitm.ejb.ValidatorRemote; import ibase.webitm.ejb.ValidatorRemote;
......
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