Package de.xanders.data.customer.dao

Examples of de.xanders.data.customer.dao.Opportunity


    /**
     * @see OpportunityService#getOpportunityById(java.lang.Long)
     */
    protected OpportunityVO handleGetOpportunityById(java.lang.Long opportunityId)
        throws java.lang.Exception {
      Opportunity opportunity = this.getOpportunityDao().load(opportunityId);
      OpportunityVO opportunityVO = this.getOpportunityDao().toOpportunityVO(opportunity);
      CustAccountService custAccountService = DataServiceLocator.instance().getCustAccountService();
      opportunityVO.setCustAccountVO(custAccountService.toCustAccountVO(opportunity.getCustAccount()));
      return opportunityVO;           
    }
View Full Code Here


        throws java.lang.Exception {
      List list = new ArrayList();
        Collection opportunityCollection = this.getOpportunityDao().findByCriteria(opportunityCriteria);
        Iterator iterator = opportunityCollection.iterator();
        while (iterator.hasNext()) {
          Opportunity opportunity = (Opportunity) iterator.next();
          OpportunityVO opportunityVO = this.getOpportunityDao().toOpportunityVO(opportunity);
          CustAccountService custAccountService = DataServiceLocator.instance().getCustAccountService();
          opportunityVO.setCustAccountVO(custAccountService.toCustAccountVO(opportunity.getCustAccount()));
          list.add(opportunityVO);
        }
        return list;                     
    }
View Full Code Here

    /**
     * @see OpportunityService#saveOpportunity(OpportunityVO)
     */
    protected OpportunityVO handleSaveOpportunity(OpportunityVO oppportunityVO)
        throws java.lang.Exception {
      Opportunity opportunity = this.getOpportunityDao().opportunityVOToEntity(oppportunityVO);
        if (opportunity.getOpportunityId() == null) {
            opportunity = this.getOpportunityDao().create(opportunity);
        }
        else {
            this.getOpportunityDao().update(opportunity);           
        }   
View Full Code Here

TOP

Related Classes of de.xanders.data.customer.dao.Opportunity

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.