Examples of IMenuDAO


Examples of it.eng.spagobi.wapp.dao.IMenuDAO

    SessionContainer permSess = sessCont.getPermanentContainer();
    IEngUserProfile profile = (IEngUserProfile)permSess.getAttribute(IEngUserProfile.ENG_USER_PROFILE);

    String idMenu = (String) request.getAttribute(DetailMenuModule.MENU_ID);
    Integer id = new Integer(idMenu);
    IMenuDAO dao=DAOFactory.getMenuDAO();
    dao.setUserProfile(profile);
    dao.moveUpMenu(id);
  }
View Full Code Here

Examples of it.eng.spagobi.wapp.dao.IMenuDAO

    SessionContainer permSess = sessCont.getPermanentContainer();
    IEngUserProfile profile = (IEngUserProfile)permSess.getAttribute(IEngUserProfile.ENG_USER_PROFILE);

    String idMenu = (String) request.getAttribute(DetailMenuModule.MENU_ID);
    Integer id = new Integer(idMenu);
    IMenuDAO dao=DAOFactory.getMenuDAO();
    dao.setUserProfile(profile);
    dao.moveDownMenu(id);
  }
View Full Code Here

Examples of it.eng.spagobi.wapp.dao.IMenuDAO

   
    Menu menu = recoverMenuDetails(request, mod);
    response.setAttribute(MENU, menu);
    response.setAttribute(AdmintoolsConstants.MODALITY, mod);
    IMenuDAO menuDao=DAOFactory.getMenuDAO();
    menuDao.setUserProfile(profile);
    // if there are some validation errors into the errorHandler does not write into DB
    Collection errors = errorHandler.getErrors();
    if (errors != null && errors.size() > 0) {
      Iterator iterator = errors.iterator();
      while (iterator.hasNext()) {
        Object error = iterator.next();
        if (error instanceof EMFValidationError) {
          Integer parentMenuId = menu.getParentId();
          Menu parentMenu = null;
          if (parentMenuId != null) {
            parentMenu = menuDao.loadMenuByID(parentMenuId);
          }
          if (parentMenu== null) {
            throw new EMFUserError(EMFErrorSeverity.ERROR, "10001", messageBundle);
          } else {
            response.setAttribute(PARENT_ID, parentMenu.getMenuId());
          }
          return;
        }
      }
    }

    if(mod.equalsIgnoreCase(AdmintoolsConstants.DETAIL_INS)) {     
      menuDao.insertMenu(menu);
    } else if(mod.equalsIgnoreCase(AdmintoolsConstants.DETAIL_MOD)) {
      menuDao.modifyMenu(menu);
    }


    response.setAttribute(AdmintoolsConstants.LOOPBACK, "true");
  }
View Full Code Here

Examples of it.eng.spagobi.wapp.dao.IMenuDAO

   */
  private void delMenu(SourceBean request, String mod, SourceBean response)
  throws EMFUserError, SourceBeanException {
    try {
      String id = (String)request.getAttribute(MENU_ID);
      IMenuDAO menudao = DAOFactory.getMenuDAO();
      Menu menu = menudao.loadMenuByID(Integer.valueOf(id));
      SessionContainer permSess = getRequestContainer().getSessionContainer().getPermanentContainer();
      menudao.eraseMenu(menu);

    } catch (EMFUserError eex) {
      throw new EMFUserError(EMFErrorSeverity.ERROR, "10002", messageBundle);
    } catch (Exception ex) {
      throw new EMFUserError(EMFErrorSeverity.ERROR, 100);
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.