Examples of OpportunityLocal


Examples of com.centraview.sale.opportunity.OpportunityLocal

                }
                break;
              case ActivityVO.ACTIVITY_LINK_OPPORTUNITY : // Opportunity - from module table
                try {
                  OpportunityLocalHome home = (OpportunityLocalHome)ic.lookup("local/Opportunity");
                  OpportunityLocal local = home.create();
                  local.setDataSource(this.dataSource);
                  String opportunityName = local.getOpportunityName(linkId);
                  app.setRelatedFieldID(linkId);
                  app.setRelatedFieldValue(opportunityName);
                  app.setRelatedTypeID(ActivityVO.ACTIVITY_LINK_OPPORTUNITY);
                  app.setRelatedTypeValue("Opportunity");
                } catch (Exception e) {
View Full Code Here

Examples of com.centraview.sale.opportunity.OpportunityLocal

      if ((oldIncludeFlag != newIncludeFlag) || newIncludeFlag) {
        // get EJB to Opportunity
        int opportunityID = Integer.parseInt(proposalForm.getOpportunityid());
        InitialContext ic = CVUtility.getInitialContext();
        OpportunityLocalHome home = (OpportunityLocalHome)ic.lookup("local/Opportunity");
        OpportunityLocal local = home.create();
        local.setDataSource(this.dataSource);
        float opportunityTotal = local.updateTotalAmount(opportunityID);
        local.updateForcastAmount(opportunityTotal, opportunityID);
        // do the update
      }
      CvFileFacade cvf = new CvFileFacade();
      // while updating for attached file ids, only commiting them as
      // isTemporary=NO is to be done.
View Full Code Here

Examples of com.centraview.sale.opportunity.OpportunityLocal

          {
            case 30: // Opportunity - from module table
              try
              {
                OpportunityLocalHome home = (OpportunityLocalHome)ic.lookup("local/Opportunity");
                OpportunityLocal local = home.create();
                local.setDataSource(this.dataSource);
                String opportunityName = local.getOpportunityName(linkId);
                flvo.setRelatedFieldID(linkId);
                flvo.setRelatedFieldValue(opportunityName);
                flvo.setRelatedTypeID(30);
                flvo.setRelatedTypeValue("Opportunity");
              } catch (Exception e) {
View Full Code Here

Examples of com.centraview.sale.opportunity.OpportunityLocal

    try {

      // System.out.println("deleteOpportunity---1");
      InitialContext ic = CVUtility.getInitialContext();
      OpportunityLocalHome home = (OpportunityLocalHome)ic.lookup("local/Opportunity");
      OpportunityLocal local = home.create();
      local.setDataSource(this.dataSource);
      result = local.deleteOpportunity(userid, elementid);
    } catch (CreateException ce) {
      throw new EJBException(ce);
    } catch (NamingException re) {
      throw new EJBException(re);
    }
View Full Code Here

Examples of com.centraview.sale.opportunity.OpportunityLocal

    int rowID = 0;

    try {
      InitialContext ic = CVUtility.getInitialContext();
      OpportunityLocalHome home = (OpportunityLocalHome)ic.lookup("local/Opportunity");
      OpportunityLocal remote = home.create();
      remote.setDataSource(this.dataSource);
      ctx.getUserTransaction().begin();
      rowID = remote.addOpportunity(userId, oVO);
      ctx.getUserTransaction().commit();
    } catch (Exception e) {
      System.out.println("Failed in SaleFacade adding Opportunity");
      e.printStackTrace();
    }
View Full Code Here

Examples of com.centraview.sale.opportunity.OpportunityLocal

      throw new AuthorizationFailedException("Opportunities - updateOpportunity");

    try {
      InitialContext ic = CVUtility.getInitialContext();
      OpportunityLocalHome home = (OpportunityLocalHome)ic.lookup("local/Opportunity");
      OpportunityLocal remote = home.create();
      remote.setDataSource(this.dataSource);
      ctx.getUserTransaction().begin();
      remote.updateOpportunity(userId, oVO);
      ctx.getUserTransaction().commit();

    } catch (Exception e) {
      System.out.println("Failed in SaleFacade adding Opportunity");
      e.printStackTrace();
View Full Code Here

Examples of com.centraview.sale.opportunity.OpportunityLocal

  {
    HashMap opportunityRelatedInfo = new HashMap();
    try {
      InitialContext ic = CVUtility.getInitialContext();
      OpportunityLocalHome home = (OpportunityLocalHome)ic.lookup("local/Opportunity");
      OpportunityLocal remote = home.create();
      remote.setDataSource(this.dataSource);
      opportunityRelatedInfo = remote.getOpportunityRelatedInfo(userId, opportunityId);
    } catch (Exception e) {
      System.out.println("Failed in SaleFacade geting Opportunity Related Info");
      e.printStackTrace();
    }
    return opportunityRelatedInfo;
View Full Code Here

Examples of com.centraview.sale.opportunity.OpportunityLocal

  {
    String opportunityID = "0";
    try {
      InitialContext ic = CVUtility.getInitialContext();
      OpportunityLocalHome home = (OpportunityLocalHome)ic.lookup("local/Opportunity");
      OpportunityLocal remote = home.create();
      remote.setDataSource(this.dataSource);
      opportunityID = remote.getOpportunityID(activityId);
    } catch (Exception e) {
      System.out.println("Failed in SaleFacade geting Opportunity ID when we pass ActivityID ");
      e.printStackTrace();
    }
    return opportunityID;
View Full Code Here

Examples of com.centraview.sale.opportunity.OpportunityLocal

    OpportunityVO oVO = null;
    try {
      InitialContext ic = CVUtility.getInitialContext();
      OpportunityLocalHome home = (OpportunityLocalHome)ic.lookup("local/Opportunity");
      OpportunityLocal remote = home.create();
      remote.setDataSource(this.dataSource);
      oVO = remote.getOpportunity(userId, opportunityId);

    } catch (Exception e) {
      System.out.println("Failed in SaleFacade geting Opportunity");
      e.printStackTrace();
    }
View Full Code Here

Examples of com.centraview.sale.opportunity.OpportunityLocal

  {
    String opportunityName = "";
    try {
      InitialContext ic = CVUtility.getInitialContext();
      OpportunityLocalHome home = (OpportunityLocalHome)ic.lookup("local/Opportunity");
      OpportunityLocal local = home.create();
      local.setDataSource(this.dataSource);
      opportunityName = local.getOpportunityName(OpportunityID);
    } catch (Exception exe) {
      exe.printStackTrace();
    }
    return opportunityName;
  }
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.