You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ofbiz.apache.org by ar...@apache.org on 2017/12/23 10:23:34 UTC
svn commit: r1819131 - in /ofbiz/ofbiz-framework/trunk/applications/order:
template/entry/BillSettings.ftl widget/ordermgr/OrderEntryOrderScreens.xml
Author: arunpatidar
Date: Sat Dec 23 10:23:34 2017
New Revision: 1819131
URL: http://svn.apache.org/viewvc?rev=1819131&view=rev
Log:
Improved: 'Order Entry Payment Settings' should not be hard coded (OFBIZ-9618)
Thanks Renuka Srishti for your contribution.
Modified:
ofbiz/ofbiz-framework/trunk/applications/order/template/entry/BillSettings.ftl
ofbiz/ofbiz-framework/trunk/applications/order/widget/ordermgr/OrderEntryOrderScreens.xml
Modified: ofbiz/ofbiz-framework/trunk/applications/order/template/entry/BillSettings.ftl
URL: http://svn.apache.org/viewvc/ofbiz/ofbiz-framework/trunk/applications/order/template/entry/BillSettings.ftl?rev=1819131&r1=1819130&r2=1819131&view=diff
==============================================================================
--- ofbiz/ofbiz-framework/trunk/applications/order/template/entry/BillSettings.ftl (original)
+++ ofbiz/ofbiz-framework/trunk/applications/order/template/entry/BillSettings.ftl Sat Dec 23 10:23:34 2017
@@ -469,22 +469,27 @@ function makeExpDate() {
<input type="hidden" name="createNew" value="${(requestParameters.createNew)!}"/>
<table width="100%" border="0" cellpadding="1" cellspacing="0">
<#if "Y" != requestParameters.createNew?default("")>
- <tr>
- <td nowrap="nowrap"><label><input type="radio" name="paymentMethodTypeAndId" value="EXT_OFFLINE" <#if checkOutPaymentId?? && "EXT_OFFLINE" == checkOutPaymentId>checked="checked"</#if> onchange="setCheckoutPaymentId(this.value)" onclick="setCheckoutPaymentId(this.value)"/> ${uiLabelMap.OrderPaymentOfflineCheckMoney}</label></td>
- </tr>
- <tr><td colspan="2"><hr /></td></tr>
- <tr>
- <td width="1%" nowrap="nowrap"><label><input type="radio" name="paymentMethodTypeAndId" value="EXT_COD" <#if checkOutPaymentId?? && "EXT_COD" == checkOutPaymentId>checked="checked"</#if> onchange="setCheckoutPaymentId(this.value)" onclick="setCheckoutPaymentId(this.value)"/> ${uiLabelMap.OrderCOD}</label></td>
- </tr>
- <tr><td colspan="2"><hr /></td></tr>
+ <#assign paymentMethodTypeAndIds = productStorePaymentMethodTypeIdMap.keySet() />
+ <#list paymentMethodTypeAndIds as paymentMethodTypeAndId>
+ <#assign paymentMethodTypeAndIdList = EntityQuery.use(delegator).from("PaymentMethodType").where("paymentMethodTypeId", paymentMethodTypeAndId).queryOne()!/>
+ <tr>
+ <td width="1%" nowrap="nowrap">
+ <label>
+ <input type="radio" name="paymentMethodTypeAndId" value=${paymentMethodTypeAndId!} <#if checkOutPaymentId?? && paymentMethodTypeAndId == checkOutPaymentId>checked="checked"</#if> onchange="setCheckoutPaymentId(this.value)" onclick="setCheckoutPaymentId(this.value)"/>
+ ${paymentMethodTypeAndIdList.get("description")!}
+ </label>
+ </td>
+ </tr>
+ </#list>
+ <#else>
+ <tr>
+ <td width='1%' nowrap="nowrap"><label><input type="radio" name="paymentMethodTypeAndId" value="CC" onchange="setCheckoutPaymentId(this.value)" onclick="setCheckoutPaymentId(this.value)"/>${uiLabelMap.AccountingVisaMastercardAmexDiscover}</label></td>
+ </tr>
+ <tr><td colspan="2"><hr /></td></tr>
+ <tr>
+ <td width='1%' nowrap="nowrap"><label><input type="radio" name="paymentMethodTypeAndId" value="EFT" onchange="setCheckoutPaymentId(this.value)" onclick="setCheckoutPaymentId(this.value)"/>${uiLabelMap.AccountingAHCElectronicCheck}</label></td>
+ </tr>
</#if>
- <tr>
- <td width='1%' nowrap="nowrap"><label><input type="radio" name="paymentMethodTypeAndId" value="CC" onchange="setCheckoutPaymentId(this.value)" onclick="setCheckoutPaymentId(this.value)"/>${uiLabelMap.AccountingVisaMastercardAmexDiscover}</label></td>
- </tr>
- <tr><td colspan="2"><hr /></td></tr>
- <tr>
- <td width='1%' nowrap="nowrap"><label><input type="radio" name="paymentMethodTypeAndId" value="EFT" onchange="setCheckoutPaymentId(this.value)" onclick="setCheckoutPaymentId(this.value)"/>${uiLabelMap.AccountingAHCElectronicCheck}</label></td>
- </tr>
</table>
</form>
</#if>
Modified: ofbiz/ofbiz-framework/trunk/applications/order/widget/ordermgr/OrderEntryOrderScreens.xml
URL: http://svn.apache.org/viewvc/ofbiz/ofbiz-framework/trunk/applications/order/widget/ordermgr/OrderEntryOrderScreens.xml?rev=1819131&r1=1819130&r2=1819131&view=diff
==============================================================================
--- ofbiz/ofbiz-framework/trunk/applications/order/widget/ordermgr/OrderEntryOrderScreens.xml (original)
+++ ofbiz/ofbiz-framework/trunk/applications/order/widget/ordermgr/OrderEntryOrderScreens.xml Sat Dec 23 10:23:34 2017
@@ -164,6 +164,7 @@ under the License.
<set field="stepTitleId" value="OrderOrderEntryPaymentSettings"/>
<set field="stepLabelId" value="AccountingPayment"/>
<script location="component://order/groovyScripts/entry/BillSettings.groovy"/>
+ <script location="component://order/groovyScripts/entry/StorePaymentOptions.groovy"/>
</actions>
<widgets>
<decorator-screen name="CommonOrderCheckoutDecorator">