svn commit: r704645 - in /ofbiz/trunk/specialpurpose: pos/data/ webpos/config/ webpos/script/org/ofbiz/webpos/event/ webpos/servicedef/ webpos/webapp/webpos/WEB-INF/actions/cart/ webpos/webapp/webpos/buttons/ webpos/webapp/webpos/payment/ webpos/widget/

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

svn commit: r704645 - in /ofbiz/trunk/specialpurpose: pos/data/ webpos/config/ webpos/script/org/ofbiz/webpos/event/ webpos/servicedef/ webpos/webapp/webpos/WEB-INF/actions/cart/ webpos/webapp/webpos/buttons/ webpos/webapp/webpos/payment/ webpos/widget/

mrisaliti
Author: mrisaliti
Date: Tue Oct 14 12:48:26 2008
New Revision: 704645

URL: http://svn.apache.org/viewvc?rev=704645&view=rev
Log:
PAYMENT SET REF. button is not working correctly because it sets now only the first payment of the cart (Issue OFBIZ-1998)

Modified:
    ofbiz/trunk/specialpurpose/pos/data/DemoRetail.xml
    ofbiz/trunk/specialpurpose/webpos/config/WebPosUiLabels.xml
    ofbiz/trunk/specialpurpose/webpos/script/org/ofbiz/webpos/event/ManagerEvents.xml
    ofbiz/trunk/specialpurpose/webpos/script/org/ofbiz/webpos/event/PaymentEvents.xml
    ofbiz/trunk/specialpurpose/webpos/script/org/ofbiz/webpos/event/PromoEvents.xml
    ofbiz/trunk/specialpurpose/webpos/servicedef/services_payment.xml
    ofbiz/trunk/specialpurpose/webpos/webapp/webpos/WEB-INF/actions/cart/MicroCart.groovy
    ofbiz/trunk/specialpurpose/webpos/webapp/webpos/buttons/Payment.ftl
    ofbiz/trunk/specialpurpose/webpos/webapp/webpos/payment/PaySetRef.ftl
    ofbiz/trunk/specialpurpose/webpos/widget/PaymentScreens.xml

Modified: ofbiz/trunk/specialpurpose/pos/data/DemoRetail.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/pos/data/DemoRetail.xml?rev=704645&r1=704644&r2=704645&view=diff
==============================================================================
--- ofbiz/trunk/specialpurpose/pos/data/DemoRetail.xml (original)
+++ ofbiz/trunk/specialpurpose/pos/data/DemoRetail.xml Tue Oct 14 12:48:26 2008
@@ -53,7 +53,7 @@
         authDeclinedMessage="There has been a problem with your method of payment. Please try a different method or call customer service."
         authFraudMessage="Your order has been rejected and your account has been disabled due to fraud."
         authErrorMessage="Problem connecting to payment processor."
-        styleSheet="" headerLogo="" autoApproveInvoice="Y" shipIfCaptureFails="Y" autoApproveOrder="Y"/>
+        styleSheet="" headerLogo="/images/ofbiz_logo.jpg" autoApproveInvoice="Y" shipIfCaptureFails="Y" autoApproveOrder="Y"/>
 
     <ProductStorePaymentSetting productStoreId="9100" paymentMethodTypeId="CREDIT_CARD" paymentServiceTypeEnumId="PRDS_PAY_AUTH" paymentService="alwaysApproveWithCaptureCCProcessor"/>
     <ProductStorePaymentSetting productStoreId="9100" paymentMethodTypeId="CREDIT_CARD" paymentServiceTypeEnumId="PRDS_PAY_RELEASE" paymentService="testCCRelease"/>

Modified: ofbiz/trunk/specialpurpose/webpos/config/WebPosUiLabels.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/webpos/config/WebPosUiLabels.xml?rev=704645&r1=704644&r2=704645&view=diff
==============================================================================
--- ofbiz/trunk/specialpurpose/webpos/config/WebPosUiLabels.xml (original)
+++ ofbiz/trunk/specialpurpose/webpos/config/WebPosUiLabels.xml Tue Oct 14 12:48:26 2008
@@ -425,7 +425,7 @@
     </property>
     <property key="WebPosPaymentSetRef">
         <value xml:lang="en">Set payment reference</value>
-        <value xml:lang="it">Imposta riferimento pagamento</value>
+        <value xml:lang="it">Imposta rif. pagamento</value>
     </property>
     <property key="WebPosPromoCode">
         <value xml:lang="en">Enter Promo Code:</value>

Modified: ofbiz/trunk/specialpurpose/webpos/script/org/ofbiz/webpos/event/ManagerEvents.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/webpos/script/org/ofbiz/webpos/event/ManagerEvents.xml?rev=704645&r1=704644&r2=704645&view=diff
==============================================================================
--- ofbiz/trunk/specialpurpose/webpos/script/org/ofbiz/webpos/event/ManagerEvents.xml (original)
+++ ofbiz/trunk/specialpurpose/webpos/script/org/ofbiz/webpos/event/ManagerEvents.xml Tue Oct 14 12:48:26 2008
@@ -20,6 +20,7 @@
 <simple-methods xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://www.ofbiz.org/dtds/simple-methods.xsd">
     <simple-method method-name="openTerminal" short-description="Open Terminal" login-required="true">
         <if-not-empty field="parameters.confirm">
+            <set field="posTerminalId" value="null"/>
             <call-class-method class-name="org.ofbiz.webpos.WebPosEvents" method-name="getWebPosSession" ret-field-name="webPosSession">
                 <field field-name="request" type="javax.servlet.http.HttpServletRequest"/>
                 <field field-name="posTerminalId" type="String"/>
@@ -78,6 +79,7 @@
     
     <simple-method method-name="closeTerminal" short-description="Close Terminal" login-required="true">
         <if-not-empty field="parameters.confirm">
+            <set field="posTerminalId" value="null"/>
             <call-class-method class-name="org.ofbiz.webpos.WebPosEvents" method-name="getWebPosSession" ret-field-name="webPosSession">
                 <field field-name="request" type="javax.servlet.http.HttpServletRequest"/>
                 <field field-name="posTerminalId" type="String"/>
@@ -184,6 +186,7 @@
     
     <simple-method method-name="voidOrder" short-description="Void Order" login-required="true">
         <if-not-empty field="parameters.confirm">
+            <set field="posTerminalId" value="null"/>
             <call-class-method class-name="org.ofbiz.webpos.WebPosEvents" method-name="getWebPosSession" ret-field-name="webPosSession">
                 <field field-name="request" type="javax.servlet.http.HttpServletRequest"/>
                 <field field-name="posTerminalId" type="String"/>
@@ -252,6 +255,7 @@
     </simple-method>
     
     <simple-method method-name="shutdown" short-description="Shutdown" login-required="true">
+        <set field="posTerminalId" value="null"/>
         <call-class-method class-name="org.ofbiz.webpos.WebPosEvents" method-name="getWebPosSession" ret-field-name="webPosSession">
             <field field-name="request" type="javax.servlet.http.HttpServletRequest"/>
             <field field-name="posTerminalId" type="String"/>
@@ -275,6 +279,7 @@
     
     <simple-method method-name="paidOutAndIn" short-description="Paid Out and In" login-required="true">
         <if-not-empty field="parameters.confirm">
+            <set field="posTerminalId" value="null"/>
             <call-class-method class-name="org.ofbiz.webpos.WebPosEvents" method-name="getWebPosSession" ret-field-name="webPosSession">
                 <field field-name="request" type="javax.servlet.http.HttpServletRequest"/>
                 <field field-name="posTerminalId" type="String"/>
@@ -335,6 +340,7 @@
     
     <simple-method method-name="modifyPrice" short-description="Modify Price" login-required="true">
         <if-not-empty field="parameters.confirm">
+            <set field="posTerminalId" value="null"/>
             <call-class-method class-name="org.ofbiz.webpos.WebPosEvents" method-name="getWebPosSession" ret-field-name="webPosSession">
                 <field field-name="request" type="javax.servlet.http.HttpServletRequest"/>
                 <field field-name="posTerminalId" type="String"/>

Modified: ofbiz/trunk/specialpurpose/webpos/script/org/ofbiz/webpos/event/PaymentEvents.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/webpos/script/org/ofbiz/webpos/event/PaymentEvents.xml?rev=704645&r1=704644&r2=704645&view=diff
==============================================================================
--- ofbiz/trunk/specialpurpose/webpos/script/org/ofbiz/webpos/event/PaymentEvents.xml (original)
+++ ofbiz/trunk/specialpurpose/webpos/script/org/ofbiz/webpos/event/PaymentEvents.xml Tue Oct 14 12:48:26 2008
@@ -20,6 +20,7 @@
 <simple-methods xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://www.ofbiz.org/dtds/simple-methods.xsd">
     <simple-method method-name="payCash" short-description="Pay Cash" login-required="true">
         <if-not-empty field="parameters.confirm">
+            <set field="posTerminalId" value="null"/>
             <call-class-method class-name="org.ofbiz.webpos.WebPosEvents" method-name="getWebPosSession" ret-field-name="webPosSession">
                 <field field-name="request" type="javax.servlet.http.HttpServletRequest"/>
                 <field field-name="posTerminalId" type="String"/>
@@ -75,6 +76,7 @@
     
     <simple-method method-name="payCheck" short-description="Pay Check" login-required="true">
         <if-not-empty field="parameters.confirm">
+            <set field="posTerminalId" value="null"/>
             <call-class-method class-name="org.ofbiz.webpos.WebPosEvents" method-name="getWebPosSession" ret-field-name="webPosSession">
                 <field field-name="request" type="javax.servlet.http.HttpServletRequest"/>
                 <field field-name="posTerminalId" type="String"/>
@@ -151,6 +153,7 @@
     
     <simple-method method-name="payGiftCard" short-description="Pay Gift Card" login-required="true">
         <if-not-empty field="parameters.confirm">
+            <set field="posTerminalId" value="null"/>
             <call-class-method class-name="org.ofbiz.webpos.WebPosEvents" method-name="getWebPosSession" ret-field-name="webPosSession">
                 <field field-name="request" type="javax.servlet.http.HttpServletRequest"/>
                 <field field-name="posTerminalId" type="String"/>
@@ -223,6 +226,7 @@
     
     <simple-method method-name="payCredit" short-description="Pay Credit Card" login-required="true">
         <if-not-empty field="parameters.confirm">
+            <set field="posTerminalId" value="null"/>
             <call-class-method class-name="org.ofbiz.webpos.WebPosEvents" method-name="getWebPosSession" ret-field-name="webPosSession">
                 <field field-name="request" type="javax.servlet.http.HttpServletRequest"/>
                 <field field-name="posTerminalId" type="String"/>
@@ -381,6 +385,7 @@
     </simple-method>
     
     <simple-method method-name="processSale" short-description="Process Sale" login-required="true">
+        <set field="posTerminalId" value="null"/>
         <call-class-method class-name="org.ofbiz.webpos.WebPosEvents" method-name="getWebPosSession" ret-field-name="webPosSession">
             <field field-name="request" type="javax.servlet.http.HttpServletRequest"/>
             <field field-name="posTerminalId" type="String"/>
@@ -398,8 +403,9 @@
         </if-not-empty>
     </simple-method>
     
-    <simple-method method-name="setRefNum" short-description="Set Payment Refernce Number" login-required="true">
+    <simple-method method-name="setRefNum" short-description="Set Payment Reference Number" login-required="true">
         <if-not-empty field="parameters.confirm">
+            <set field="posTerminalId" value="null"/>
             <call-class-method class-name="org.ofbiz.webpos.WebPosEvents" method-name="getWebPosSession" ret-field-name="webPosSession">
                 <field field-name="request" type="javax.servlet.http.HttpServletRequest"/>
                 <field field-name="posTerminalId" type="String"/>
@@ -407,16 +413,83 @@
             <if-not-empty field="webPosSession">
                 <call-object-method obj-field-name="webPosSession" method-name="getCurrentTransaction" ret-field-name="webPosTransaction"/>
                 <check-errors/>
-                <set field="idx" from-field="parameters.idx" type="Integer"/>
-                <set field="refNum" from-field="parameters.refNum"/>
-                <set field="authCode" from-field="parameters.authCode"/>
-                <call-object-method obj-field-name="webPosTransaction" method-name="setPaymentRefNum">
-                    <field field-name="idx" type="int"/>
-                    <field field-name="refNum" type="String"/>
-                    <field field-name="authCode" type="String"/>
-                </call-object-method>
+                <set field="payment" value="0" type="Integer"/>
+                <call-object-method obj-field-name="webPosTransaction" method-name="getNumberOfPayments" ret-field-name="numPayments"/>
                 <check-errors/>
-                <log level="info" message="Set the reference number ${idx} to ${refNum}"/>
+                <while>
+                    <condition>                    
+                        <if-compare-field field="payment" to-field="numPayments" operator="less"/>
+                    </condition>
+                    <then>
+                        <call-object-method obj-field-name="webPosTransaction" method-name="getPaymentMethodTypeId" ret-field-name="paymentMethodTypeId">
+                            <field field-name="payment" type="int"/>
+                        </call-object-method>
+                        <check-errors/>
+                        <if-not-empty field="paymentMethodTypeId">      
+                            <if-compare field="paymentMethodTypeId" value="PERSONAL_CHECK" operator="equals">
+                                <log level="always" message="refNumCheck ${parameters.refNumCheck}"/>
+                                <if-not-empty field="parameters.refNumCheck">
+                                    <set field="idx" from-field="payment"/>
+                <set field="refNum" from-field="parameters.refNumCheck"/>
+                <call-object-method obj-field-name="webPosTransaction" method-name="setPaymentRefNum">
+                    <field field-name="idx" type="int"/>
+                    <field field-name="refNum" type="String"/>
+                    <field field-name="authCode" type="String"/>
+                </call-object-method>
+                <check-errors/>
+                <log level="info" message="Set the reference number ${idx} to ${refNum} for payment CHECK"/>
+                            <else>
+                                    <set field="payment" from-field="numPayments"/>
+                                    <add-error><fail-property resource="WebPosUiLabels" property="WebPosPaymentCheckMissingRefNum"/></add-error>
+                                    <check-errors/>
+                                </else>
+                                </if-not-empty>
+                            </if-compare>        
+                            <if-compare field="paymentMethodTypeId" value="GIFT_CARD" operator="equals">
+                                <log level="always" message="refNumGift ${parameters.refNumGift}"/>
+                                <if-not-empty field="parameters.refNumGift">
+                                    <set field="idx" from-field="payment"/>
+                <set field="refNum" from-field="parameters.refNumGift"/>
+                <call-object-method obj-field-name="webPosTransaction" method-name="setPaymentRefNum">
+                    <field field-name="idx" type="int"/>
+                    <field field-name="refNum" type="String"/>
+                    <field field-name="authCode" type="String"/>
+                </call-object-method>
+                <check-errors/>
+                <log level="info" message="Set the reference number ${idx} to ${refNum} for payment GIFT CARD"/>
+                            <else>
+                                <set field="payment" from-field="numPayments"/>
+                                    <add-error><fail-property resource="WebPosUiLabels" property="WebPosPaymentGiftCardMissingRefNum"/></add-error>
+                                    <check-errors/>
+                                </else>
+                                </if-not-empty>                    
+                            </if-compare>        
+                            <if-compare field="paymentMethodTypeId" value="CREDIT_CARD" operator="equals">
+                                <log level="always" message="refNumCredit ${parameters.refNumCredit}"/>
+                                <if-not-empty field="parameters.refNumCredit">
+                                    <set field="idx" from-field="payment"/>
+                <set field="refNum" from-field="parameters.refNumCredit"/>
+                <call-object-method obj-field-name="webPosTransaction" method-name="setPaymentRefNum">
+                    <field field-name="idx" type="int"/>
+                    <field field-name="refNum" type="String"/>
+                    <field field-name="authCode" type="String"/>
+                </call-object-method>
+                <check-errors/>
+                <log level="info" message="Set the reference number ${idx} to ${refNum} for payment CREDIT CARD"/>
+                            <else>
+                                    <set field="payment" from-field="numPayments"/>
+                                    <add-error><fail-property resource="WebPosUiLabels" property="WebPosPaymentCredictCardMissingRefNum"/></add-error>
+                                    <check-errors/>
+                                </else>
+                                </if-not-empty>                    
+                            </if-compare>        
+                        </if-not-empty>
+                        <calculate field-name="payment" type="Integer">
+                            <calcop field-name="payment" operator="add"/>
+                            <number value="1"/>
+                        </calculate>
+                    </then>
+                </while>
             <else>
                 <add-error><fail-property resource="WebPosUiLabels" property="WebPosNotLoggedIn"/></add-error>
                 <check-errors/>
@@ -427,6 +500,7 @@
     
     <simple-method method-name="clearPayment" short-description="Clear Payment" login-required="true">
         <if-not-empty field="parameters.confirm">
+            <set field="posTerminalId" value="null"/>
             <call-class-method class-name="org.ofbiz.webpos.WebPosEvents" method-name="getWebPosSession" ret-field-name="webPosSession">
                 <field field-name="request" type="javax.servlet.http.HttpServletRequest"/>
                 <field field-name="posTerminalId" type="String"/>
@@ -520,6 +594,7 @@
     </simple-method>
     
     <simple-method method-name="clearAllPayments" short-description="Clear All Payments" login-required="true">
+        <set field="posTerminalId" value="null"/>
         <call-class-method class-name="org.ofbiz.webpos.WebPosEvents" method-name="getWebPosSession" ret-field-name="webPosSession">
             <field field-name="request" type="javax.servlet.http.HttpServletRequest"/>
             <field field-name="posTerminalId" type="String"/>

Modified: ofbiz/trunk/specialpurpose/webpos/script/org/ofbiz/webpos/event/PromoEvents.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/webpos/script/org/ofbiz/webpos/event/PromoEvents.xml?rev=704645&r1=704644&r2=704645&view=diff
==============================================================================
--- ofbiz/trunk/specialpurpose/webpos/script/org/ofbiz/webpos/event/PromoEvents.xml (original)
+++ ofbiz/trunk/specialpurpose/webpos/script/org/ofbiz/webpos/event/PromoEvents.xml Tue Oct 14 12:48:26 2008
@@ -20,6 +20,7 @@
 <simple-methods xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://www.ofbiz.org/dtds/simple-methods.xsd">
     <simple-method method-name="addPromoCode" short-description="Add Promotion Code" login-required="true">
         <if-not-empty field="parameters.confirm">
+            <set field="posTerminalId" value="null"/>
             <call-class-method class-name="org.ofbiz.webpos.WebPosEvents" method-name="getWebPosSession" ret-field-name="webPosSession">
                 <field field-name="request" type="javax.servlet.http.HttpServletRequest"/>
                 <field field-name="posTerminalId" type="String"/>

Modified: ofbiz/trunk/specialpurpose/webpos/servicedef/services_payment.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/webpos/servicedef/services_payment.xml?rev=704645&r1=704644&r2=704645&view=diff
==============================================================================
--- ofbiz/trunk/specialpurpose/webpos/servicedef/services_payment.xml (original)
+++ ofbiz/trunk/specialpurpose/webpos/servicedef/services_payment.xml Tue Oct 14 12:48:26 2008
@@ -65,9 +65,9 @@
     <service name="setRefNum" engine="simple" auth="false"
              location="org/ofbiz/webpos/event/PaymentEvents.xml" invoke="setRefNum">
         <description>Set Payment Refernce Number</description>
-        <attribute name="idx" type="String" mode="IN" optional="true"/>
-        <attribute name="refNum" type="String" mode="IN" optional="true"/>
-        <attribute name="authCode" type="String" mode="IN" optional="true"/>
+        <attribute name="refNumCheck"  type="String" mode="IN" optional="true"/>
+        <attribute name="refNumGift"   type="String" mode="IN" optional="true"/>
+        <attribute name="refNumCredit" type="String" mode="IN" optional="true"/>
     </service>
 
     <service name="clearPayment" engine="simple" auth="false"

Modified: ofbiz/trunk/specialpurpose/webpos/webapp/webpos/WEB-INF/actions/cart/MicroCart.groovy
URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/webpos/webapp/webpos/WEB-INF/actions/cart/MicroCart.groovy?rev=704645&r1=704644&r2=704645&view=diff
==============================================================================
--- ofbiz/trunk/specialpurpose/webpos/webapp/webpos/WEB-INF/actions/cart/MicroCart.groovy (original)
+++ ofbiz/trunk/specialpurpose/webpos/webapp/webpos/WEB-INF/actions/cart/MicroCart.groovy Tue Oct 14 12:48:26 2008
@@ -55,12 +55,16 @@
                 }
                 else if ("PERSONAL_CHECK".equals(paymentInfo.paymentMethodTypeId)) {
                     context.checkAmount = (context.checkAmount) ? context.checkAmount + amount : amount;
+                    requestParameters.refNumCheck = paymentInfo.refNum[0];
                 }
                 else if ("GIFT_CARD".equals(paymentInfo.paymentMethodTypeId)) {
                     context.giftAmount = (context.giftAmount) ? context.giftAmount + amount : amount;
+                    requestParameters.refNumGift = paymentInfo.refNum[0];
                 }
                 else if ("CREDIT_CARD".equals(paymentInfo.paymentMethodTypeId)) {
                     context.creditAmount = (context.creditAmount) ? context.creditAmount + amount : amount;
+                    requestParameters.refNumCredit = paymentInfo.refNum[0];
+                    print("paymentInfo "+paymentInfo);
                 }
             }
         }

Modified: ofbiz/trunk/specialpurpose/webpos/webapp/webpos/buttons/Payment.ftl
URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/webpos/webapp/webpos/buttons/Payment.ftl?rev=704645&r1=704644&r2=704645&view=diff
==============================================================================
--- ofbiz/trunk/specialpurpose/webpos/webapp/webpos/buttons/Payment.ftl (original)
+++ ofbiz/trunk/specialpurpose/webpos/webapp/webpos/buttons/Payment.ftl Tue Oct 14 12:48:26 2008
@@ -41,7 +41,11 @@
             </#if>
         </td>
         <td>
-            <a href="<@ofbizUrl>AddPaySetRef</@ofbizUrl>" class="posButton">${uiLabelMap.WebPosButtonPaySetRef}</a>
+            <#if (totalPayments > 0.00)>
+                <a href="<@ofbizUrl>AddPaySetRef</@ofbizUrl>" class="posButton">${uiLabelMap.WebPosButtonPaySetRef}</a>
+            <#else>
+                <span class="disabled">${uiLabelMap.WebPosButtonPaySetRef}</span>
+            </#if>
         </td>
     </tr>
     <tr>

Modified: ofbiz/trunk/specialpurpose/webpos/webapp/webpos/payment/PaySetRef.ftl
URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/webpos/webapp/webpos/payment/PaySetRef.ftl?rev=704645&r1=704644&r2=704645&view=diff
==============================================================================
--- ofbiz/trunk/specialpurpose/webpos/webapp/webpos/payment/PaySetRef.ftl (original)
+++ ofbiz/trunk/specialpurpose/webpos/webapp/webpos/payment/PaySetRef.ftl Tue Oct 14 12:48:26 2008
@@ -18,31 +18,46 @@
 -->
 
 <div id="panel">
-    <form method="post" action="<@ofbizUrl>PaySetRef</@ofbizUrl>" name="PaySetRefForm">
-        <table border="0">
-            <tr>
-                <td colspan="2"">&nbsp;</td>
-            </tr>
-            <tr>
-                <td><b>${uiLabelMap.WebPosPaymentSetRef}</b></td>
-                <td>
-                    <input type="hidden" name="idx" id="idx" value="0"/>
-                    <input type="text" name="refNum" id="refNum"/>
-                </td>
-                
-            </tr>
-            <tr>
-                <td colspan="2"">&nbsp;</td>
-            </tr>
-            <tr>
-                <td colspan="2" align="center">
-                    <input type="submit" value="${uiLabelMap.CommonConfirm}" name="confirm"/>
-                    <input type="submit" value="${uiLabelMap.CommonCancel}"/>
-                </td>
-            </tr>
-        </table>
-    </form>
+  <form method="post" action="<@ofbizUrl>PaySetRef</@ofbizUrl>" name="PaySetRefForm">
+    <table border="0">
+      <tr>
+        <td>&nbsp;</td>
+        <td>&nbsp;</td>
+        <td><b><u>${uiLabelMap.WebPosPaymentSetRef}</u></b></td>
+      </tr>
+      <#if (checkAmount?default(0) > 0.00)>
+      <tr>
+        <td><b>${(paymentCheck.get("description", locale))?if_exists}</b></td>
+        <td align="right"><@ofbizCurrency amount=checkAmount isoCode=shoppingCart.getCurrency()/></td>
+        <td align="center"><input type="text" name="refNumCheck" id="refNumCheck" value="${requestParameters.refNumCheck?if_exists}"/></td>
+      </tr>
+      </#if>
+      <#if (giftAmount?default(0) > 0.00)>
+      <tr>
+        <td><b>${(paymentGift.get("description", locale))?if_exists}</b></td>
+        <td align="right"><@ofbizCurrency amount=giftAmount isoCode=shoppingCart.getCurrency()/></td>
+        <td align="center"><input type="text" name="refNumGift" id="refNumGift" value="${requestParameters.refNumGift?if_exists}"/></td>
+      </tr>
+      </#if>
+      <#if (creditAmount?default(0) > 0.00)>
+      <tr>
+        <td><b>${(paymentCredit.get("description", locale))?if_exists}</b></td>
+        <td align="right"><@ofbizCurrency amount=creditAmount isoCode=shoppingCart.getCurrency()/></td>
+        <td align="center"><input type="text" name="refNumCredit" id="refNumCredit" value="${requestParameters.refNumCredit?if_exists}"/></td>
+      </tr>
+      </#if>
+      <tr>
+        <td colspan="3">&nbsp;</td>
+      </tr>
+      <tr>
+        <td colspan="3" align="center">
+          <input type="submit" value="${uiLabelMap.CommonConfirm}" name="confirm"/>
+          <input type="submit" value="${uiLabelMap.CommonCancel}"/>
+        </td>
+      </tr>
+    </table>
+  </form>
 </div>
 <script language="javascript" type="text/javascript">
-    document.PaySetRefForm.refNum.focus();
+    document.PaySetRefForm.refNumCheck.focus();
 </script>
\ No newline at end of file

Modified: ofbiz/trunk/specialpurpose/webpos/widget/PaymentScreens.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/webpos/widget/PaymentScreens.xml?rev=704645&r1=704644&r2=704645&view=diff
==============================================================================
--- ofbiz/trunk/specialpurpose/webpos/widget/PaymentScreens.xml (original)
+++ ofbiz/trunk/specialpurpose/webpos/widget/PaymentScreens.xml Tue Oct 14 12:48:26 2008
@@ -102,6 +102,7 @@
             <actions>
                 <set field="rightbarScreenName" value="rightbar_payment"/>
                 <set field="titleProperty" value="WebPosPageTitlePaySetRef"/>
+                <script location="component://webpos/webapp/webpos/WEB-INF/actions/cart/MicroCart.groovy"/>
             </actions>
             <widgets>
                 <include-screen name="SearchProducts" location="component://webpos/widget/WebPosScreens.xml"/>