You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ofbiz.apache.org by jl...@apache.org on 2011/11/12 21:44:14 UTC
svn commit: r1201321 - in
/ofbiz/trunk/applications/order/webapp/ordermgr/order: orderinfo.ftl
orderlist.ftl orderpaymentinfo.ftl
Author: jleroux
Date: Sat Nov 12 20:44:14 2011
New Revision: 1201321
URL: http://svn.apache.org/viewvc?rev=1201321&view=rev
Log:
A patch from Dimitri Unruh "DateTime Dispay improvements in OrderComponent" https://issues.apache.org/jira/browse/OFBIZ-4557
Some DateTime improvements in OrderComponent.
DateTime will be show with locale and timezone
Modified:
ofbiz/trunk/applications/order/webapp/ordermgr/order/orderinfo.ftl
ofbiz/trunk/applications/order/webapp/ordermgr/order/orderlist.ftl
ofbiz/trunk/applications/order/webapp/ordermgr/order/orderpaymentinfo.ftl
Modified: ofbiz/trunk/applications/order/webapp/ordermgr/order/orderinfo.ftl
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/order/webapp/ordermgr/order/orderinfo.ftl?rev=1201321&r1=1201320&r2=1201321&view=diff
==============================================================================
--- ofbiz/trunk/applications/order/webapp/ordermgr/order/orderinfo.ftl (original)
+++ ofbiz/trunk/applications/order/webapp/ordermgr/order/orderinfo.ftl Sat Nov 12 20:44:14 2011
@@ -24,7 +24,7 @@ under the License.
<#assign externalOrder = "(" + orderHeader.externalId + ")"/>
</#if>
<#assign orderType = orderHeader.getRelatedOne("OrderType")/>
- <li class="h3"> ${orderType?if_exists.get("description", locale)?default(uiLabelMap.OrderOrder)} ${uiLabelMap.CommonNbr}<a href="<@o...@ofbizUrl>">${orderId}</a> ${externalOrder?if_exists} [ <a href="<@o...@ofbizUrl>" target="_blank">PDF</a> ]</li>
+ <li class="h3"> ${orderType?if_exists.get("description", locale)?default(uiLabelMap.OrderOrder)} ${uiLabelMap.CommonNbr} <a href="<@o...@ofbizUrl>">${orderId}</a> ${externalOrder?if_exists} [ <a href="<@o...@ofbizUrl>" target="_blank">PDF</a> ]</li>
<#if currentStatus.statusId == "ORDER_APPROVED" && orderHeader.orderTypeId == "SALES_ORDER">
<li class="h3"><a target="_BLANK" href="javascript:document.PrintOrderPickSheet.submit()">${uiLabelMap.FormFieldTitle_printPickSheet}</a>
<form name="PrintOrderPickSheet" method="post" action="<@o...@ofbizUrl>">
@@ -83,7 +83,7 @@ under the License.
<input type="hidden" name="fromDate" value="${fromDate?if_exists}"/>
</form>
</li>
- </#if>
+ </#if>
<#if setOrderCompleteOption>
<li><a href="javascript:document.OrderCompleteOrder.submit()">${uiLabelMap.OrderCompleteOrder}</a>
<form name="OrderCompleteOrder" method="post" action="<@o...@ofbizUrl>">
@@ -117,7 +117,7 @@ under the License.
<#assign loopStatusItem = orderHeaderStatus.getRelatedOne("StatusItem")>
<#assign userlogin = orderHeaderStatus.getRelatedOne("UserLogin")>
<div>
- ${loopStatusItem.get("description",locale)} - ${orderHeaderStatus.statusDatetime?default("0000-00-00 00:00:00")?string}
+ ${loopStatusItem.get("description",locale)} <#if orderHeaderStatus.statusDatetime?has_content>- ${Static["org.ofbiz.base.util.UtilFormatOut"].formatDateTime(orderHeaderStatus.statusDatetime, "", locale, timeZone)?default("0000-00-00 00:00:00")}</#if>
${uiLabelMap.CommonBy} - <#--${Static["org.ofbiz.party.party.PartyHelper"].getPartyName(delegator, userlogin.getString("partyId"), true)}--> [${orderHeaderStatus.statusUserLogin}]
</div>
@@ -129,7 +129,7 @@ under the License.
<tr>
<td align="right" valign="top" width="15%" class="label"> ${uiLabelMap.OrderDateOrdered}</td>
<td width="5%"> </td>
- <td valign="top" width="80%">${orderHeader.orderDate.toString()}</td>
+ <td valign="top" width="80%"><#if orderHeader.orderDate?has_content>${Static["org.ofbiz.base.util.UtilFormatOut"].formatDateTime(orderHeader.orderDate, "", locale, timeZone)!}</#if></td>
</tr>
<tr><td colspan="3"><hr /></td></tr>
<tr>
@@ -199,7 +199,7 @@ under the License.
<tr>
<td align="right" valign="top" width="15%" class="label"> ${uiLabelMap.FormFieldTitle_cancelBackOrderDate}</td>
<td width="5%"> </td>
- <td valign="top" width="80%">${orderItem.cancelBackOrderDate?if_exists}</td>
+ <td valign="top" width="80%"><#if orderItem.cancelBackOrderDate?has_content>${Static["org.ofbiz.base.util.UtilFormatOut"].formatDateTime(orderItem.cancelBackOrderDate, "", locale, timeZone)!}</#if></td>
</tr>
</#if>
<#if distributorId?exists>
@@ -261,8 +261,8 @@ under the License.
<form name="setInvoicePerShipment" method="post" action="<@o...@ofbizUrl>">
<input type = "hidden" name="orderId" value="${orderId}"/>
<select name="invoicePerShipment">
- <option value="Y" <#if (orderHeader.invoicePerShipment)?if_exists == "Y">selected="selected" </#if>>Y</option>
- <option value="N" <#if (orderHeader.invoicePerShipment)?if_exists == "N">selected="selected" </#if>>N</option>
+ <option value="Y" <#if (orderHeader.invoicePerShipment)?if_exists == "Y">selected="selected" </#if>>${uiLabelMap.CommonYes}</option>
+ <option value="N" <#if (orderHeader.invoicePerShipment)?if_exists == "N">selected="selected" </#if>>${uiLabelMap.CommonNo}</option>
</select>
<input type="submit" class="smallSubmit" value="${uiLabelMap.CommonUpdate}"/>
</form>
Modified: ofbiz/trunk/applications/order/webapp/ordermgr/order/orderlist.ftl
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/order/webapp/ordermgr/order/orderlist.ftl?rev=1201321&r1=1201320&r2=1201321&view=diff
==============================================================================
--- ofbiz/trunk/applications/order/webapp/ordermgr/order/orderlist.ftl (original)
+++ ofbiz/trunk/applications/order/webapp/ordermgr/order/orderlist.ftl Sat Nov 12 20:44:14 2011
@@ -183,7 +183,7 @@ under the License.
</#if>
<#assign productStore = orderHeader.getRelatedOneCache("ProductStore")?if_exists />
<tr>
- <td>${orderHeader.orderDate.toString()}</td>
+ <td><#if orderHeader.orderDate?has_content>${Static["org.ofbiz.base.util.UtilFormatOut"].formatDateTime(orderHeader.orderDate, "", locale, timeZone)!}</#if></td>
<td>
<a href="<@o...@ofbizUrl>" class="buttontext">${orderHeader.orderId}</a>
</td>
Modified: ofbiz/trunk/applications/order/webapp/ordermgr/order/orderpaymentinfo.ftl
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/order/webapp/ordermgr/order/orderpaymentinfo.ftl?rev=1201321&r1=1201320&r2=1201321&view=diff
==============================================================================
--- ofbiz/trunk/applications/order/webapp/ordermgr/order/orderpaymentinfo.ftl (original)
+++ ofbiz/trunk/applications/order/webapp/ordermgr/order/orderpaymentinfo.ftl Sat Nov 12 20:44:14 2011
@@ -40,7 +40,7 @@ under the License.
</div>
<div class="screenlet-body">
<table class="basic-table" cellspacing='0'>
- <#assign orderTypeId = orderReadHelper.getOrderTypeId()>
+ <#assign orderTypeId = orderReadHelper.getOrderTypeId()>
<#if orderTypeId == "PURCHASE_ORDER">
<tr>
<th>${uiLabelMap.AccountingPaymentID}</th>
@@ -54,13 +54,13 @@ under the License.
<#assign statusItem = payment.getRelatedOne("StatusItem")>
<#assign partyName = delegator.findOne("PartyNameView", {"partyId" : payment.partyIdTo}, true)>
<tr>
- <#if security.hasPermission("PAY_INFO_VIEW", session) || security.hasPermission("PAY_INFO_ADMIN", session)>
+ <#if security.hasPermission("PAY_INFO_VIEW", session) || security.hasPermission("PAY_INFO_ADMIN", session)>
<td><a href="/accounting/control/paymentOverview?paymentId=${payment.paymentId}">${payment.paymentId}</a></td>
<#else>
<td>${payment.paymentId}</td>
</#if>
<td>${partyName.groupName?if_exists}${partyName.lastName?if_exists} ${partyName.firstName?if_exists} ${partyName.middleName?if_exists}
- <#if security.hasPermission("PARTYMGR_VIEW", session) || security.hasPermission("PARTYMGR_ADMIN", session)>
+ <#if security.hasPermission("PARTYMGR_VIEW", session) || security.hasPermission("PARTYMGR_ADMIN", session)>
[<a href="/partymgr/control/viewprofile?partyId=${partyId}">${partyId}</a>]
<#else>
[${partyId}]
@@ -87,7 +87,7 @@ under the License.
</tr>
</#if>
<#else>
-
+
<#-- order payment status -->
<tr>
<td align="center" valign="top" width="29%" class="label"> ${uiLabelMap.OrderStatusHistory}</td>
@@ -99,7 +99,7 @@ under the License.
<#assign statusItem = orderPaymentStatus.getRelatedOne("StatusItem")?if_exists>
<#if statusItem?has_content>
<div>
- ${statusItem.get("description",locale)} - ${orderPaymentStatus.statusDatetime?default("0000-00-00 00:00:00")?string}
+ ${statusItem.get("description",locale)} <#if orderPaymentStatus.statusDatetime?has_content>- ${Static["org.ofbiz.base.util.UtilFormatOut"].formatDateTime(orderPaymentStatus.statusDatetime, "", locale, timeZone)!}</#if>
${uiLabelMap.CommonBy} - [${orderPaymentStatus.statusUserLogin?if_exists}]
</div>
@@ -166,7 +166,7 @@ under the License.
<#list gatewayResponses as gatewayResponse>
<#assign transactionCode = gatewayResponse.getRelatedOne("TranCodeEnumeration")>
${(transactionCode.get("description",locale))?default("Unknown")}:
- ${gatewayResponse.transactionDate.toString()}
+ <#if gatewayResponse.transactionDate?has_content>${Static["org.ofbiz.base.util.UtilFormatOut"].formatDateTime(gatewayResponse.transactionDate, "", locale, timeZone)!} </#if>
<@ofbizCurrency amount=gatewayResponse.amount isoCode=currencyUomId/><br />
(<span class="label">${uiLabelMap.OrderReference}</span> ${gatewayResponse.referenceNum?if_exists}
<span class="label">${uiLabelMap.OrderAvs}</span> ${gatewayResponse.gatewayAvsResult?default("N/A")}
@@ -326,7 +326,7 @@ under the License.
<#list gatewayResponses as gatewayResponse>
<#assign transactionCode = gatewayResponse.getRelatedOne("TranCodeEnumeration")>
${(transactionCode.get("description",locale))?default("Unknown")}:
- ${gatewayResponse.transactionDate.toString()}
+ <#if gatewayResponse.transactionDate?has_content>${Static["org.ofbiz.base.util.UtilFormatOut"].formatDateTime(gatewayResponse.transactionDate, "", locale, timeZone)!} </#if>
<@ofbizCurrency amount=gatewayResponse.amount isoCode=currencyUomId/><br />
(<span class="label">${uiLabelMap.OrderReference}</span> ${gatewayResponse.referenceNum?if_exists}
<span class="label">${uiLabelMap.OrderAvs}</span> ${gatewayResponse.gatewayAvsResult?default("N/A")}