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

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


    }
    if(hasErrors()){
      return INPUT;
    }
   
    PriceList priceList;
    if(getPriceList().getId() == null || "".equalsIgnoreCase(getPriceList().getId())){
      priceList = new PriceList();
      logInfo = new LogInformation();
      logInfo.setCreateBy(sessionCredentials.getCurrentUser().getId());
      logInfo.setCreateDate(new Timestamp(System.currentTimeMillis()));
      msg = "Succesfully Add"+getPriceList().getName();
    } else {
      priceList = (PriceList) manager.getById(PriceList.class, getPriceList().getId());
      logInfo = priceList.getLogInformation();
      msg = "Succesfully Edit"+getPriceList().getName();
    }
   
    logInfo.setActiveFlag(getActive());
    logInfo.setLastUpdateBy(sessionCredentials.getCurrentUser().getId());
    logInfo.setLastUpdateDate(new Timestamp(System.currentTimeMillis()));
   
    priceList.setLogInformation(logInfo);
    priceList.setCurrency(getCurrency());
    priceList.setName(getPriceList().getName());
    priceList.setDescription(getPriceList().getDescription());
    priceList.setPdefault(getPriceList().getPdefault());
    priceList.setSalesPriceList(getPriceList().getSalesPriceList());
    priceList.setEnforcePriceLimit(getPriceList().getEnforcePriceLimit());
    priceList.setPriceIncludesTax(getPriceList().getPriceIncludesTax());
    priceList.setPriceDecision(getPriceList().getPriceDecision());
   
    manager.save(priceList);
    setPriceList(priceList);
    return SUCCESS;
  }
View Full Code Here

TOP

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

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.