Package org.jallinone.registers.transportmotives.java

Examples of org.jallinone.registers.transportmotives.java.TransportMotiveVO


   */
  public VOListResponse insertTransportMotives(ArrayList list,String serverLanguageId,String username,String defCompanyCodeSys01SYS03,ArrayList customizedFields) throws Throwable {
    Connection conn = null;
    try {
      if (this.conn==null) conn = getConn(); else conn = this.conn;
      TransportMotiveVO vo = null;

      BigDecimal progressiveSYS10 = null;

      Map attribute2dbField = new HashMap();
      attribute2dbField.put("transportMotiveCodeREG20","TRANSPORT_MOTIVE_CODE");
      attribute2dbField.put("progressiveSys10REG20","PROGRESSIVE_SYS10");
      attribute2dbField.put("enabledREG20","ENABLED");

      Response res = null;
      for(int i=0;i<list.size();i++) {
        vo = (TransportMotiveVO)list.get(i);
        vo.setEnabledREG20("Y");

        // insert record in SYS10...
        progressiveSYS10 = TranslationUtils.insertTranslations(vo.getDescriptionSYS10(),username,conn);
        vo.setProgressiveSys10REG20(progressiveSYS10);

        // insert into REG20...
        res = CustomizeQueryUtil.insertTable(
            conn,
            new UserSessionParameters(username),
View Full Code Here


    Connection conn = null;
    try {
      if (this.conn==null) conn = getConn(); else conn = this.conn;


      TransportMotiveVO oldVO = null;
      TransportMotiveVO newVO = null;
      Response res = null;

      for(int i=0;i<oldVOs.size();i++) {
        oldVO = (TransportMotiveVO)oldVOs.get(i);
        newVO = (TransportMotiveVO)newVOs.get(i);

        // update SYS10 table...
        TranslationUtils.updateTranslation(oldVO.getDescriptionSYS10(),newVO.getDescriptionSYS10(),newVO.getProgressiveSys10REG20(),serverLanguageId,username,conn);

        HashSet pkAttrs = new HashSet();
        pkAttrs.add("transportMotiveCodeREG20");

        HashMap attr2dbFields = new HashMap();
View Full Code Here

  public VOResponse deleteTransportMotives(ArrayList list,String serverLanguageId,String username) throws Throwable {
    PreparedStatement pstmt = null;
    Connection conn = null;
    try {
      if (this.conn==null) conn = getConn(); else conn = this.conn;
      TransportMotiveVO vo = null;
      for(int i=0;i<list.size();i++) {
        // logically delete the record in REG20...
        vo = (TransportMotiveVO)list.get(i);
        pstmt = conn.prepareStatement(
          "update REG20_TRANSPORT_MOTIVES set ENABLED='N',LAST_UPDATE_USER=?,LAST_UPDATE_DATE=?  where TRANSPORT_MOTIVE_CODE='"+vo.getTransportMotiveCodeREG20()+"'"
        );
        pstmt.setString(1,username);
        pstmt.setTimestamp(2,new java.sql.Timestamp(System.currentTimeMillis()));
        pstmt.execute();
        pstmt.close();
View Full Code Here

TOP

Related Classes of org.jallinone.registers.transportmotives.java.TransportMotiveVO

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.