📄 orderitems.ftl
字号:
<#-- * Copyright (c) 2001-2005 The Open For Business Project - www.ofbiz.org * * Permission is hereby granted, free of charge, to any person obtaining a * copy of this software and associated documentation files (the "Software"), * to deal in the Software without restriction, including without limitation * the rights to use, copy, modify, merge, publish, distribute, sublicense, * and/or sell copies of the Software, and to permit persons to whom the * Software is furnished to do so, subject to the following conditions: * * The above copyright notice and this permission notice shall be included * in all copies or substantial portions of the Software. * * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY * CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT * OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR * THE USE OR OTHER DEALINGS IN THE SOFTWARE. * *@author Andy Zeneski (jaz@ofbiz.org) *@author David E. Jones (jonesde@ofbiz.org) *@version $Rev: 6642 $ *@since 2.1--><#-- NOTE: this template is used for the orderstatus screen in ecommerce AND for order notification emails through the OrderNoticeEmail.ftl file --><#-- the "urlPrefix" value will be prepended to URLs by the ofbizUrl transform if/when there is no "request" object in the context --><#if baseEcommerceSecureUrl?exists><#assign urlPrefix = baseEcommerceSecureUrl/></#if><div class="screenlet"> <div class="screenlet-header"> <div style="float: right;"> <#if maySelectItems?default("N") == "Y"> <a href="javascript:document.addCommonToCartForm.add_all.value='true';document.addCommonToCartForm.submit()" class="submenutext">${uiLabelMap.EcommerceAddAlltoCart}</a><a href="javascript:document.addCommonToCartForm.add_all.value='false';document.addCommonToCartForm.submit()" class="submenutext">${uiLabelMap.EcommerceAddCheckedToCart}</a><a href="<@ofbizUrl>createShoppingListFromOrder?orderId=${orderHeader.orderId}&frequency=6&intervalNumber=1&shoppingListTypeId=SLT_AUTO_REODR</@ofbizUrl>" class="submenutextright">${uiLabelMap.OrderSendMeThisEveryMonth}</a> </#if> </div> <div class="boxhead"> ${uiLabelMap.OrderOrderItems}</div> </div> <div class="screenlet-body"> <table width="100%" border="0" cellpadding="0"> <tr align="left" valign="bottom"> <td width="35%" align="left"><span class="tableheadtext"><b>${uiLabelMap.EcommerceProduct}</b></span></td> <#if maySelectItems?default("N") == "Y"> <td width="10%" align="right"><span class="tableheadtext"><b>${uiLabelMap.OrderQtyOrdered}</b></span></td> <td width="10%" align="right"><span class="tableheadtext"><b>${uiLabelMap.OrderQtyShipped}</b></span></td> <td width="10%" align="right"><span class="tableheadtext"><b>${uiLabelMap.OrderQtyCanceled}</b></span></td> <#else> <td width="10%" align="right"> </td> <td width="10%" align="right"> </td> <td width="10%" align="right"><span class="tableheadtext"><b>${uiLabelMap.OrderQtyOrdered}</b></span></td> </#if> <td width="10%" align="right"><span class="tableheadtext"><b>${uiLabelMap.EcommerceUnitPrice}</b></span></td> <td width="10%" align="right"><span class="tableheadtext"><b>${uiLabelMap.OrderAdjustments}</b></span></td> <td width="10%" align="right"><span class="tableheadtext"><b>${uiLabelMap.CommonSubtotal}</b></span></td> <#if maySelectItems?default("N") == "Y"> <td width="5%" align="right"> </td> </#if> </tr> <#list orderItems as orderItem> <#-- get info from workeffort and calculate rental quantity, if it was a rental item --> <#assign rentalQuantity = 1> <#-- no change if no rental item --> <#if orderItem.orderItemTypeId == "RENTAL_ORDER_ITEM" && workEfforts?exists> <#list workEfforts as workEffort> <#if workEffort.workEffortId == orderItem.orderItemSeqId> <#assign rentalQuantity = localOrderReadHelper.getWorkEffortRentalQuantity(workEffort)> <#assign workEffortSave = workEffort> <#break> </#if> </#list> <#else> <#assign WorkOrderItemFulfillments = orderItem.getRelated("WorkOrderItemFulfillment")?if_exists> <#if WorkOrderItemFulfillments?has_content> <#list WorkOrderItemFulfillments as WorkOrderItemFulfillment> <#assign workEffortSave = WorkOrderItemFulfillment.getRelatedOneCache("WorkEffort")?if_exists> <#break> </#list> </#if> </#if> <tr><td colspan="10"><hr class="sepbar"/></td></tr> <tr> <#if !orderItem.productId?exists || orderItem.productId == "_?_"> <td colspan="1" valign="top"> <b><div class="tabletext"> >> ${orderItem.itemDescription}</div></b> </td> <#else> <#assign product = orderItem.getRelatedOneCache("Product")?if_exists/> <#-- should always exist because of FK constraint, but just in case --> <td valign="top"> <div class="tabletext"> <a href="<@ofbizUrl>product?product_id=${orderItem.productId}</@ofbizUrl>" class="linktext">${orderItem.productId} - ${orderItem.itemDescription}</a> </div> <div class="tabletext" style="font-size: xx-small;"> <#if product?has_content> <#if product.piecesIncluded?exists && product.piecesIncluded?long != 0> [${uiLabelMap.EcommercePieces}: ${product.piecesIncluded}] </#if> <#if (product.quantityIncluded?exists && product.quantityIncluded?double != 0) || product.quantityUomId?has_content> <#assign quantityUom = product.getRelatedOneCache("QuantityUom")?if_exists/> [${uiLabelMap.CommonQuantity}: ${product.quantityIncluded?if_exists} ${((quantityUom.abbreviation)?default(product.quantityUomId))?if_exists}] </#if> <#if (product.weight?exists && product.weight?double != 0) || product.weightUomId?has_content> <#assign weightUom = product.getRelatedOneCache("WeightUom")?if_exists/> [${uiLabelMap.CommonWeight}: ${product.weight?if_exists} ${((weightUom.abbreviation)?default(product.weightUomId))?if_exists}] </#if> <#if (product.productHeight?exists && product.productHeight?double != 0) || product.heightUomId?has_content> <#assign heightUom = product.getRelatedOneCache("HeightUom")?if_exists/> [${uiLabelMap.CommonHeight}: ${product.productHeight?if_exists} ${((heightUom.abbreviation)?default(product.heightUomId))?if_exists}] </#if> <#if (product.productWidth?exists && product.productWidth?double != 0) || product.widthUomId?has_content> <#assign widthUom = product.getRelatedOneCache("WidthUom")?if_exists/> [${uiLabelMap.CommonWidth}: ${product.productWidth?if_exists} ${((widthUom.abbreviation)?default(product.widthUomId))?if_exists}] </#if> <#if (product.productDepth?exists && product.productDepth?double != 0) || product.depthUomId?has_content> <#assign depthUom = product.getRelatedOneCache("DepthUom")?if_exists/> [${uiLabelMap.CommonDepth}: ${product.productDepth?if_exists} ${((depthUom.abbreviation)?default(product.depthUomId))?if_exists}] </#if> </#if> </div> <#if maySelectItems?default("N") == "Y"> <#assign returns = orderItem.getRelated("ReturnItem")?if_exists> <#if returns?has_content> <#list returns as return> <#assign returnHeader = return.getRelatedOne("ReturnHeader")> <#if returnHeader.statusId != "RETURN_CANCELLED"> <#if returnHeader.statusId == "RETURN_REQUESTED" || returnHeader.statusId == "RETURN_APPROVED"> <#assign displayState = "Return Pending"> <#else> <#assign displayState = "Returned"> </#if> <div class="tabletext"><font color="red"><b>${displayState}</b></font> (#${return.returnId})</div> </#if> </#list> </#if> </#if> </td> <#if !(maySelectItems?default("N") == "Y")> <td> </td> <td> </td>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -