You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ofbiz.apache.org by as...@apache.org on 2009/09/29 06:13:45 UTC

svn commit: r819829 - in /ofbiz/trunk/applications/accounting/src/org/ofbiz/accounting: finaccount/FinAccountServices.java invoice/InvoiceServices.java

Author: ashish
Date: Tue Sep 29 04:13:44 2009
New Revision: 819829

URL: http://svn.apache.org/viewvc?rev=819829&view=rev
Log:
Encouraging use of Generics.

Modified:
    ofbiz/trunk/applications/accounting/src/org/ofbiz/accounting/finaccount/FinAccountServices.java
    ofbiz/trunk/applications/accounting/src/org/ofbiz/accounting/invoice/InvoiceServices.java

Modified: ofbiz/trunk/applications/accounting/src/org/ofbiz/accounting/finaccount/FinAccountServices.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/src/org/ofbiz/accounting/finaccount/FinAccountServices.java?rev=819829&r1=819828&r2=819829&view=diff
==============================================================================
--- ofbiz/trunk/applications/accounting/src/org/ofbiz/accounting/finaccount/FinAccountServices.java (original)
+++ ofbiz/trunk/applications/accounting/src/org/ofbiz/accounting/finaccount/FinAccountServices.java Tue Sep 29 04:13:44 2009
@@ -74,7 +74,7 @@
         try {
             // find the most recent (active) service credit account for the specified party
             String partyId = (String) context.get("partyId");
-            Map lookupMap = UtilMisc.toMap("finAccountTypeId", finAccountTypeId, "ownerPartyId", partyId);
+            Map<String, String> lookupMap = UtilMisc.toMap("finAccountTypeId", finAccountTypeId, "ownerPartyId", partyId);
 
             // if a productStoreId is present, restrict the accounts returned using the store's payToPartyId
             String productStoreId = (String) context.get("productStoreId");

Modified: ofbiz/trunk/applications/accounting/src/org/ofbiz/accounting/invoice/InvoiceServices.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/src/org/ofbiz/accounting/invoice/InvoiceServices.java?rev=819829&r1=819828&r2=819829&view=diff
==============================================================================
--- ofbiz/trunk/applications/accounting/src/org/ofbiz/accounting/invoice/InvoiceServices.java (original)
+++ ofbiz/trunk/applications/accounting/src/org/ofbiz/accounting/invoice/InvoiceServices.java Tue Sep 29 04:13:44 2009
@@ -166,10 +166,10 @@
             }
 
             // get list of previous invoices for the order
-            List billedItems = delegator.findByAnd("OrderItemBilling", UtilMisc.toMap("orderId", orderId));
+            List<GenericValue> billedItems = delegator.findByAnd("OrderItemBilling", UtilMisc.toMap("orderId", orderId));
             if (billedItems.size() > 0) {
                 boolean nonDigitalInvoice = false;
-                Iterator bii = billedItems.iterator();
+                Iterator<GenericValue> bii = billedItems.iterator();
                 while (bii.hasNext() && !nonDigitalInvoice) {
                     GenericValue orderItemBilling = (GenericValue) bii.next();
                     GenericValue invoiceItem = orderItemBilling.getRelatedOne("InvoiceItem");