Package org.araneaframework.example.main.business.model

Examples of org.araneaframework.example.main.business.model.ContractMO


    wizard.addPage(company);
    wizard.addPage(person);
    wizard.addPage(notes);
   
    if (id != null) {
      ContractMO contract = (ContractMO) getGeneralDAO().getById(ContractMO.class, id);
      company.setCompany(contract.getCompany());
      person.setPerson(contract.getPerson());
      notes.setNotes(contract.getNotes());
    }
   
    wizard.addEventListener(new WizardContext.EventListener() {
      public void onGoto(Widget page) throws Exception {}     
      public void onSubmit() throws Exception {
        log.debug("Event 'save' received!");
        if (validate()) {
          ContractMO contract = id != null ? (ContractMO) getGeneralDAO().getById(ContractMO.class, id) : new ContractMO();
          contract.setCompany(company.getCompany());
          contract.setPerson(person.getPerson());
          contract.setNotes(notes.getNotes());
          if (id != null) {
            getGeneralDAO().edit(contract);
          } else {
            id = getGeneralDAO().add(contract);               
          }
View Full Code Here

TOP

Related Classes of org.araneaframework.example.main.business.model.ContractMO

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.