All Downloads are FREE. Search and download functionalities are using the official Maven repository.

META-INF.resources.message_boards.split_thread.jsp Maven / Gradle / Ivy

There is a newer version: 5.0.117
Show newest version
<%--
/**
 * Copyright (c) 2000-present Liferay, Inc. All rights reserved.
 *
 * This library is free software; you can redistribute it and/or modify it under
 * the terms of the GNU Lesser General Public License as published by the Free
 * Software Foundation; either version 2.1 of the License, or (at your option)
 * any later version.
 *
 * This library is distributed in the hope that it will be useful, but WITHOUT
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
 * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
 * details.
 */
--%>

<%@ include file="/message_boards/init.jsp" %>

<%
String redirect = ParamUtil.getString(request, "redirect");

MBMessage message = (MBMessage)request.getAttribute(WebKeys.MESSAGE_BOARDS_MESSAGE);

MBCategory category = message.getCategory();

MBThread thread = MBThreadLocalServiceUtil.getThread(message.getThreadId());

long messageId = message.getMessageId();

long categoryId = message.getCategoryId();

MBMessage curParentMessage = null;
String parentAuthor = null;

String body = StringPool.BLANK;
boolean quote = false;
boolean splitThread = true;

boolean portletTitleBasedNavigation = GetterUtil.getBoolean(portletConfig.getInitParameter("portlet-title-based-navigation"));

String headerTitle = LanguageUtil.get(request, "split-thread");

if (portletTitleBasedNavigation) {
	portletDisplay.setShowBackIcon(true);
	portletDisplay.setURLBack(redirect);

	renderResponse.setTitle(headerTitle);
}
%>

> <% long breadcrumbsMessageId = message.getMessageId(); %>
<% MBMessageDisplay messageDisplay = MBMessageServiceUtil.getMessageDisplay(messageId, WorkflowConstants.STATUS_APPROVED); MBTreeWalker treeWalker = messageDisplay.getTreeWalker(); List messages = new ArrayList(); messages.addAll(treeWalker.getMessages()); messages = ListUtil.sort(messages, new MessageCreateDateComparator(true)); %> ;"> <% request.setAttribute(WebKeys.MESSAGE_BOARDS_TREE_WALKER, treeWalker); request.setAttribute(WebKeys.MESSAGE_BOARDS_TREE_WALKER_CATEGORY, category); request.setAttribute(WebKeys.MESSAGE_BOARDS_TREE_WALKER_CUR_MESSAGE, message); request.setAttribute(WebKeys.MESSAGE_BOARDS_TREE_WALKER_DEPTH, Integer.valueOf(0)); request.setAttribute(WebKeys.MESSAGE_BOARDS_TREE_WALKER_LAST_NODE, Boolean.valueOf(false)); request.setAttribute(WebKeys.MESSAGE_BOARDS_TREE_WALKER_SEL_MESSAGE, message); request.setAttribute(WebKeys.MESSAGE_BOARDS_TREE_WALKER_THREAD, thread); %>

function splitThread() { document.fm.body.value = getHTML(); submitForm(document.fm); } function selectCategory(categoryId, categoryName) { document.fm.mbCategoryId.value = categoryId; var nameEl = document.getElementById('categoryName'); if (categoryId == 0) { nameEl.href = ''; } else { nameEl.href = '&mbCategoryId=' + categoryId; } nameEl.innerHTML = categoryName + ' '; } function toggleExplanationPost() { if (document.getElementById('addExplanationPost').checked) { document.getElementById('explanationPost').style.display = ''; } else { document.getElementById('explanationPost').style.display = 'none'; } } <% MBBreadcrumbUtil.addPortletBreadcrumbEntries(message, request, renderResponse); PortalUtil.addPortletBreadcrumbEntry(request, LanguageUtil.get(request, "split-thread"), currentURL); %>




© 2015 - 2025 Weber Informatics LLC | Privacy Policy