Package com.liferay.portlet.polls.model

Examples of com.liferay.portlet.polls.model.PollsDisplay


    }
    else if (pollsDisplayPK == null) {
      return null;
    }
    else {
      PollsDisplay obj = null;
      String key = pollsDisplayPK.toString();

      if (Validator.isNull(key)) {
        return null;
      }
View Full Code Here


    }
    else if (pollsDisplayPK == null) {
      return null;
    }
    else {
      PollsDisplay obj = null;
      String key = pollsDisplayPK.toString();

      if (Validator.isNull(key)) {
        return null;
      }
View Full Code Here

  public PollsDisplay updateDisplay(String portletId, String questionId)
    throws PortalException, SystemException {

    PollsDisplayPK pk = new PollsDisplayPK(getUserId(), portletId);

    PollsDisplay display = null;

    try {
      display = PollsDisplayUtil.findByPrimaryKey(pk);
    }
    catch (NoSuchDisplayException nsde) {
      display = PollsDisplayUtil.create(pk);
    }

    display.setQuestionId(questionId);

    PollsDisplayUtil.update(display);

    return display;
  }
View Full Code Here

        PollsQuestion question = null;

        try {
          question = PollsQuestionManagerUtil.getQuestion(questionId);

          PollsDisplay display =
            PollsDisplayManagerUtil.updateDisplay(config.getPortletName(),
              question.getQuestionId());

          PortletAction pa = (PortletAction)InstancePool.get(
            ViewAction.class.getName());

          return pa.render(mapping, form, config, req, res);
        }
        catch (NoSuchQuestionException nsne) {
          req.removeAttribute(WebKeys.POLLS_DISPLAY);

          SessionErrors.add(
            req, NoSuchQuestionException.class.getName());
        }
      }
      else {
        try {
          PollsDisplay display = PollsDisplayManagerUtil.getDisplay(config.getPortletName());

          req.setAttribute(WebKeys.POLLS_DISPLAY, display);
        }
        catch (NoSuchDisplayException nsde) {
          req.removeAttribute(WebKeys.POLLS_DISPLAY);
View Full Code Here

    throws Exception {

    try {
//      Layout layout = (Layout)req.getAttribute(WebKeys.LAYOUT);

      PollsDisplay display = PollsDisplayManagerUtil.getDisplay(config.getPortletName());

      req.setAttribute(WebKeys.POLLS_DISPLAY, display);

      return mapping.findForward("portlet.polls_display.view");
    }
View Full Code Here

TOP

Related Classes of com.liferay.portlet.polls.model.PollsDisplay

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.