svn commit: r815248 - in /ofbiz/trunk/specialpurpose/ebay: config/EbayUiLabels.xml src/org/ofbiz/ebay/ImportOrdersFromEbay.java widget/EbayForms.xml widget/EbayMenus.xml widget/EbayScreens.xml

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

svn commit: r815248 - in /ofbiz/trunk/specialpurpose/ebay: config/EbayUiLabels.xml src/org/ofbiz/ebay/ImportOrdersFromEbay.java widget/EbayForms.xml widget/EbayMenus.xml widget/EbayScreens.xml

ashish-18
Author: ashish
Date: Tue Sep 15 10:11:50 2009
New Revision: 815248

URL: http://svn.apache.org/viewvc?rev=815248&view=rev
Log:
Now we have GetOrders request working fine so changing old screen to import only single transactions.
This will help to avoid the duplicate order being created in the system with the help of old screen for importing eBay orders.

Modified:
    ofbiz/trunk/specialpurpose/ebay/config/EbayUiLabels.xml
    ofbiz/trunk/specialpurpose/ebay/src/org/ofbiz/ebay/ImportOrdersFromEbay.java
    ofbiz/trunk/specialpurpose/ebay/widget/EbayForms.xml
    ofbiz/trunk/specialpurpose/ebay/widget/EbayMenus.xml
    ofbiz/trunk/specialpurpose/ebay/widget/EbayScreens.xml

Modified: ofbiz/trunk/specialpurpose/ebay/config/EbayUiLabels.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/ebay/config/EbayUiLabels.xml?rev=815248&r1=815247&r2=815248&view=diff
==============================================================================
--- ofbiz/trunk/specialpurpose/ebay/config/EbayUiLabels.xml (original)
+++ ofbiz/trunk/specialpurpose/ebay/config/EbayUiLabels.xml Tue Sep 15 10:11:50 2009
@@ -72,6 +72,12 @@
         <value xml:lang="th">คุณไม่มีการอนุญาตถึงการแสดงหน้านี้  ("EBAY_VIEW" ต้องการ)</value>
         <value xml:lang="zh">你没有浏览这个页面的权限(需要EBAY_VIEW)。</value>
     </property>
+    <property key="EbayImportSingleTransactionFromEbay">
+        <value xml:lang="en">Import Single Transactions</value>
+    </property>
+    <property key="EbayImportSearchSingleTransactionFromEbay">
+        <value xml:lang="en">Search Single Transactions From eBay</value>
+    </property>
     <property key="FormFieldTitle_amountPaid">
         <value xml:lang="en">Amount Paid</value>
         <value xml:lang="fr">Montant payé</value>

Modified: ofbiz/trunk/specialpurpose/ebay/src/org/ofbiz/ebay/ImportOrdersFromEbay.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/ebay/src/org/ofbiz/ebay/ImportOrdersFromEbay.java?rev=815248&r1=815247&r2=815248&view=diff
==============================================================================
--- ofbiz/trunk/specialpurpose/ebay/src/org/ofbiz/ebay/ImportOrdersFromEbay.java (original)
+++ ofbiz/trunk/specialpurpose/ebay/src/org/ofbiz/ebay/ImportOrdersFromEbay.java Tue Sep 15 10:11:50 2009
@@ -342,7 +342,7 @@
         List orders = null;
         try {
             Document docResponse = UtilXml.readXmlDocument(msg, true);
-//            Debug.logInfo("The generated string is ======= " + UtilXml.writeXmlDocument(docResponse), module);
+            //Debug.logInfo("The generated string is ======= " + UtilXml.writeXmlDocument(docResponse), module);
             Element elemResponse = docResponse.getDocumentElement();
             String ack = UtilXml.childElementValue(elemResponse, "Ack", "Failure");
             List paginationList = UtilXml.childElementList(elemResponse, "PaginationResult");
@@ -372,6 +372,10 @@
                             String itemId = "";
 
                             Element transactionElement = (Element) transactionElemIter.next();
+                            List containingOrders = UtilXml.childElementList(transactionElement, "ContainingOrder");                            
+                            if (containingOrders != null && containingOrders.size() > 0) {
+                                continue;
+                            }
                             order.put("amountPaid", UtilXml.childElementValue(transactionElement, "AmountPaid", "0"));
 
                             // retrieve buyer

Modified: ofbiz/trunk/specialpurpose/ebay/widget/EbayForms.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/ebay/widget/EbayForms.xml?rev=815248&r1=815247&r2=815248&view=diff
==============================================================================
--- ofbiz/trunk/specialpurpose/ebay/widget/EbayForms.xml (original)
+++ ofbiz/trunk/specialpurpose/ebay/widget/EbayForms.xml Tue Sep 15 10:11:50 2009
@@ -31,7 +31,7 @@
         </field>
         <field name="fromDate" title="${uiLabelMap.CommonFromDateTime}"><date-time default-value="${groovy: org.ofbiz.base.util.UtilDateTime.getDayStart(nowTimestamp)}"/></field>
         <field name="thruDate" title="${uiLabelMap.CommonThruDateTime}"><date-time default-value="${groovy: org.ofbiz.base.util.UtilDateTime.getDayEnd(nowTimestamp)}"/></field>
-        <field name="submitButton" title="${uiLabelMap.EbayImportOrdersSearchFromEbay}"><submit button-type="button"/></field>
+        <field name="submitButton" title="${uiLabelMap.EbayImportSearchSingleTransactionFromEbay}"><submit button-type="button"/></field>
     </form>
     <form name="ListOrdersFromEbay" type="multi" use-row-submit="true" list-name="orderList" target="ImportOrderFromEbay"
         odd-row-style="alternate-row" default-table-style="basic-table hover-bar">
@@ -85,7 +85,7 @@
         <field name="errorMessage"><display/></field>
         <field name="_rowSubmit" title="${uiLabelMap.CommonSelect}" use-when="${canImportOrder}"><check/></field>
         <field name="_rowSubmit" title="${uiLabelMap.CommonSelect}" use-when="!${canImportOrder}"><display/></field>
-        <field name="submitButton" title="${uiLabelMap.EbayImportOrdersFromEbay}" widget-style="smallSubmit"><submit/></field>
+        <field name="submitButton" title="${uiLabelMap.EbayImportSingleTransactionFromEbay}" widget-style="smallSubmit"><submit/></field>
     </form>
     
     <form name="FindEbayOrders" type="single" target="GetEbayOrders"

Modified: ofbiz/trunk/specialpurpose/ebay/widget/EbayMenus.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/ebay/widget/EbayMenus.xml?rev=815248&r1=815247&r2=815248&view=diff
==============================================================================
--- ofbiz/trunk/specialpurpose/ebay/widget/EbayMenus.xml (original)
+++ ofbiz/trunk/specialpurpose/ebay/widget/EbayMenus.xml Tue Sep 15 10:11:50 2009
@@ -20,7 +20,7 @@
 <menus xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://ofbiz.apache.org/dtds/widget-menu.xsd">
     <menu name="EbayAppBar" title="${uiLabelMap.EbayApplication}" extends="CommonAppBarMenu" extends-resource="component://common/widget/CommonMenus.xml">
         <menu-item name="export" title="${uiLabelMap.EbayExportToEbay}"><link target="advancedsearch"/></menu-item>
-        <menu-item name="importOrders" title="${uiLabelMap.EbayImportOrdersFromEbay}"><link target="ManageOrdersFromEbay"/></menu-item>
+        <menu-item name="importOrders" title="${uiLabelMap.EbayImportSingleTransactionFromEbay}"><link target="ManageOrdersFromEbay"/></menu-item>
         <menu-item name="eBayOrders" title="${uiLabelMap.EbayEBayOrders}"><link target="eBayOrders"/></menu-item>
     </menu>
 </menus>

Modified: ofbiz/trunk/specialpurpose/ebay/widget/EbayScreens.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/ebay/widget/EbayScreens.xml?rev=815248&r1=815247&r2=815248&view=diff
==============================================================================
--- ofbiz/trunk/specialpurpose/ebay/widget/EbayScreens.xml (original)
+++ ofbiz/trunk/specialpurpose/ebay/widget/EbayScreens.xml Tue Sep 15 10:11:50 2009
@@ -121,7 +121,7 @@
                         <container style="screenlet">
                             <container style="screenlet-title-bar">
                                 <container style="h3">
-                                    <label text="${uiLabelMap.EbayImportOrdersSearchFromEbay}"/>
+                                    <label text="${uiLabelMap.EbayImportSearchSingleTransactionFromEbay}"/>
                                 </container>
                             </container>
                             <container style="screenlet-body">