Examples of LotControl


Examples of org.blueoxygen.postila.materialmanagement.productattributes.entity.LotControl

import org.blueoxygen.cimande.LogInformation;
import org.blueoxygen.postila.materialmanagement.productattributes.entity.LotControl;

public class SaveLotControl extends LotControlForm  {
  public String execute(){
    LotControl lotControl;
    if(getLotControl().getId() == null && "".equalsIgnoreCase(getLotControl().getId())){
      lotControl = new LotControl();
      logInfo = new LogInformation();
      logInfo.setCreateBy(sessionCredentials.getCurrentUser().getId());
      logInfo.setCreateDate(new Timestamp(System.currentTimeMillis()));
    } else {
      lotControl = (LotControl) manager.getById(LotControl.class, getLotControl().getId());
      logInfo = lotControl.getLogInformation();
    }
   
    logInfo.setActiveFlag(getActive());
    logInfo.setLastUpdateBy(sessionCredentials.getCurrentUser().getId());
    logInfo.setLastUpdateDate(new Timestamp(System.currentTimeMillis()));
   
    lotControl.setLogInformation(logInfo);
    lotControl.setName(getLotControl().getName());
    lotControl.setDescription(getLotControl().getDescription());
    lotControl.setStartNo(getLotControl().getStartNo());
    lotControl.setIncrement(getLotControl().getIncrement());
    lotControl.setCurrentNext(getLotControl().getCurrentNext());
    lotControl.setPrefix(getLotControl().getPrefix());
    lotControl.setSuffix(getLotControl().getSuffix());
   
    manager.save(lotControl);
    setLotControl(lotControl);
    return SUCCESS;
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.