
META-INF.resources.bookmarks.view_entries.jsp Maven / Gradle / Ivy
<%--
/**
* 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="/bookmarks/init.jsp" %>
<%
long folderId = GetterUtil.getLong((String)request.getAttribute("view.jsp-folderId"));
SearchContainer bookmarksSearchContainer = (SearchContainer)request.getAttribute("view.jsp-bookmarksSearchContainer");
EntriesChecker entriesChecker = new EntriesChecker(liferayPortletRequest, liferayPortletResponse);
bookmarksSearchContainer.setRowChecker(entriesChecker);
entriesChecker.setCssClass("entry-selector");
if (folderId == 0) {
entriesChecker.setRememberCheckBoxStateURLRegex("mvcRenderCommandName=/bookmarks/view(&.|$)");
}
else {
entriesChecker.setRememberCheckBoxStateURLRegex("^(?!.*" + liferayPortletResponse.getNamespace() + "redirect).*(folderId=" + folderId + ")");
}
EntriesMover entriesMover = new EntriesMover(scopeGroupId);
bookmarksSearchContainer.setRowMover(entriesMover);
String displayStyle = GetterUtil.getString((String)request.getAttribute("view.jsp-displayStyle"));
boolean portletTitleBasedNavigation = GetterUtil.getBoolean(portletConfig.getInitParameter("portlet-title-based-navigation"));
if (portletTitleBasedNavigation && (folderId != BookmarksFolderConstants.DEFAULT_PARENT_FOLDER_ID) && (folderId != rootFolderId)) {
String redirect = ParamUtil.getString(request, "redirect");
if (Validator.isNotNull(redirect)) {
portletDisplay.setShowBackIcon(true);
portletDisplay.setURLBack(redirect);
}
BookmarksFolder folder = BookmarksFolderServiceUtil.getFolder(folderId);
renderResponse.setTitle(folder.getName());
}
String searchContainerId = ParamUtil.getString(request, "searchContainerId");
%>
<%@ include file="/bookmarks/cast_result.jspf" %>
<%
Map rowData = new HashMap();
rowData.put("folder", true);
rowData.put("folder-id", curFolder.getFolderId());
rowData.put("title", curFolder.getName());
row.setData(rowData);
row.setPrimaryKey(String.valueOf(curFolder.getFolderId()));
%>
<%@ include file="/bookmarks/folder_columns.jspf" %>
<%
Map rowData = new HashMap();
rowData.put("title", entry.getName());
row.setData(rowData);
row.setPrimaryKey(String.valueOf(entry.getEntryId()));
String entryHREF = themeDisplay.getPathMain() + "/bookmarks/open_entry?entryId=" + entry.getEntryId();
%>
<%@ include file="/bookmarks/entry_columns.jspf" %>
© 2015 - 2025 Weber Informatics LLC | Privacy Policy