Package org.blueoxygen.postila.materialmanagement.materialmanagementrules.entity

Examples of org.blueoxygen.postila.materialmanagement.materialmanagementrules.entity.Warehouse


   
    if(hasErrors()){
      return INPUT;
    }
   
    Warehouse warehouse;
    if(getWarehouse().getId() == null || "".equalsIgnoreCase(getWarehouse().getId())){
      warehouse = new Warehouse();
      logInfo = new LogInformation();
      logInfo.setCreateBy(sessionCredentials.getCurrentUser().getId());
      logInfo.setCreateDate(new Timestamp(System.currentTimeMillis()));
    } else {
      warehouse = (Warehouse) manager.getById(Warehouse.class, getWarehouse().getId());
      logInfo = warehouse.getLogInformation();
    }
   
    logInfo.setActiveFlag(getActive());
    logInfo.setLastUpdateBy(sessionCredentials.getCurrentUser().getId());
    logInfo.setLastUpdateDate(new Timestamp(System.currentTimeMillis()));
   
    warehouse.setLogInformation(logInfo);
    warehouse.setSearchKey(getWarehouse().getSearchKey());
    warehouse.setName(getWarehouse().getName());
    warehouse.setDescription(getWarehouse().getDescription());
    warehouse.setInTransit(getWarehouse().getInTransit());
    warehouse.setAddress(getAddress());
    warehouse.setSourceWarehouse(getSourceWarehouse());
    warehouse.setReplenishmentClass(getWarehouse().getReplenishmentClass());
   
    manager.save(warehouse);
    setWarehouse(warehouse);
    return SUCCESS;
  }
View Full Code Here

TOP

Related Classes of org.blueoxygen.postila.materialmanagement.materialmanagementrules.entity.Warehouse

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.