Example usage for com.liferay.portal.kernel.util WebKeys COMMENT

List of usage examples for com.liferay.portal.kernel.util WebKeys COMMENT

Introduction

In this page you can find the example usage for com.liferay.portal.kernel.util WebKeys COMMENT.

Prototype

String COMMENT

To view the source code for com.liferay.portal.kernel.util WebKeys COMMENT.

Click Source Link

Usage

From source file:com.liferay.comment.web.internal.asset.CommentAssetRenderer.java

License:Open Source License

@Override
public boolean include(HttpServletRequest request, HttpServletResponse response, String template)
        throws Exception {

    Comment comment = CommentManagerUtil.fetchComment(_workflowableComment.getCommentId());

    request.setAttribute(WebKeys.COMMENT, comment);

    return super.include(request, response, template);
}

From source file:com.liferay.comment.web.internal.portlet.action.EditDiscussionMVCRenderCommand.java

License:Open Source License

@Override
public String render(RenderRequest renderRequest, RenderResponse renderResponse) throws PortletException {

    long commentId = ParamUtil.getLong(renderRequest, "commentId");

    Comment comment = _commentManager.fetchComment(commentId);

    renderRequest.setAttribute(WebKeys.COMMENT, comment);

    return "/edit_discussion.jsp";
}