META-INF.resources.edit_cp_definition_configuration.jsp Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of com.liferay.commerce.product.definitions.web
Show all versions of com.liferay.commerce.product.definitions.web
Liferay Commerce Product Definitions Web
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="/init.jsp" %>
<%
CPDefinitionConfigurationDisplayContext cpDefinitionConfigurationDisplayContext = (CPDefinitionConfigurationDisplayContext)request.getAttribute(WebKeys.PORTLET_DISPLAY_CONTEXT);
CPDAvailabilityEstimate cpdAvailabilityEstimate = cpDefinitionConfigurationDisplayContext.getCPDAvailabilityEstimate();
CPDefinition cpDefinition = cpDefinitionConfigurationDisplayContext.getCPDefinition();
long cpDefinitionId = cpDefinitionConfigurationDisplayContext.getCPDefinitionId();
CPDefinitionInventory cpDefinitionInventory = cpDefinitionConfigurationDisplayContext.getCPDefinitionInventory();
List cpTaxCategories = cpDefinitionConfigurationDisplayContext.getCPTaxCategories();
boolean shippable = BeanParamUtil.getBoolean(cpDefinition, request, "shippable", true);
%>
<%
for (CPTaxCategory cpTaxCategory : cpTaxCategories) {
%>
<%
}
%>
<%
for (CPDefinitionInventoryEngine cpDefinitionInventoryEngine : cpDefinitionConfigurationDisplayContext.getCPDefinitionInventoryEngines()) {
String cpDefinitionInventoryEngineName = cpDefinitionInventoryEngine.getKey();
%>
<%
}
%>
<%
for (CommerceAvailabilityEstimate commerceAvailabilityEstimate : cpDefinitionConfigurationDisplayContext.getCommerceAvailabilityEstimates()) {
%>
<%
}
%>
<%
BigDecimal minOrderQuantity = CPDefinitionInventoryConstants.DEFAULT_MIN_ORDER_QUANTITY;
if (cpDefinitionInventory != null) {
minOrderQuantity = cpDefinitionInventory.getMinOrderQuantity();
}
%>
function(val) {
if (Number(val) > 0) {
return true;
}
return false;
}
<%
for (CommerceLowStockActivity commerceLowStockActivity : cpDefinitionConfigurationDisplayContext.getCommerceLowStockActivities()) {
String commerceLowStockActivityName = commerceLowStockActivity.getKey();
%>
<%
}
%>
<%
BigDecimal minStockQuantity = BigDecimal.ZERO;
if (cpDefinitionInventory != null) {
minStockQuantity = cpDefinitionInventory.getMinStockQuantity();
}
%>
function(val) {
if (Number(val) >= 0) {
return true;
}
return false;
}
<%
BigDecimal maxOrderQuantity = CPDefinitionInventoryConstants.DEFAULT_MAX_ORDER_QUANTITY;
if (cpDefinitionInventory != null) {
maxOrderQuantity = cpDefinitionInventory.getMaxOrderQuantity();
}
%>
function(val) {
if (Number(val) > 0) {
return true;
}
return false;
}
<%
BigDecimal multipleOrderQuantity = CPDefinitionInventoryConstants.DEFAULT_MULTIPLE_ORDER_QUANTITY;
if (cpDefinitionInventory != null) {
multipleOrderQuantity = cpDefinitionInventory.getMultipleOrderQuantity();
}
%>
function(val) {
if (Number(val) > 0) {
return true;
}
return false;
}
" id=" shippableOptions">
Liferay.Util.toggleBoxes(
' shippable',
' shippableOptions'
);