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

META-INF.resources.admin.common.select_version.jsp Maven / Gradle / Ivy

The newest version!
<%--
/**
 * SPDX-FileCopyrightText: (c) 2000 Liferay, Inc. https://liferay.com
 * SPDX-License-Identifier: LGPL-2.1-or-later OR LicenseRef-Liferay-DXP-EULA-2.0.0-2023-06
 */
--%>

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

<%
KBArticle kbArticle = (KBArticle)request.getAttribute(KBWebKeys.KNOWLEDGE_BASE_KB_ARTICLE);
int status = (Integer)request.getAttribute(KBWebKeys.KNOWLEDGE_BASE_STATUS);

int selStatus = KBArticlePermission.contains(permissionChecker, kbArticle, KBActionKeys.UPDATE) ? WorkflowConstants.STATUS_ANY : status;

int sourceVersion = ParamUtil.getInteger(request, "sourceVersion");

PortletURL portletURL = PortletURLBuilder.createRenderURL(
	renderResponse
).setMVCPath(
	"/admin/common/select_version.jsp"
).setRedirect(
	currentURL
).setParameter(
	"resourcePrimKey", kbArticle.getResourcePrimKey()
).setParameter(
	"sourceVersion", sourceVersion
).buildPortletURL();
%>


	
		
			

			
				
					
						

							<%
							int curSourceVersion = sourceVersion;
							int curTargetVersion = curKBArticle.getVersion();

							if (curTargetVersion < curSourceVersion) {
								int tempVersion = curTargetVersion;

								curTargetVersion = curSourceVersion;
								curSourceVersion = tempVersion;
							}
							%>

							
								<%= String.valueOf(curKBArticle.getVersion()) %>
							
						
						
							<%= curKBArticle.getVersion() %>
						
					
				

				
			

			
		
	




© 2015 - 2025 Weber Informatics LLC | Privacy Policy