details:   /erp/devel/pi/rev/f641668debc0
changeset: 8224:f641668debc0
user:      Harikrishnan Raja <harikrishnan.raja <at> openbravo.com>
date:      Thu Aug 26 11:05:47 2010 +0530
summary:   Fixes issue 14252: Invoice Term \"Do not invoice\" fails when 
creating Invoice from Shipment

diffstat:

 src/org/openbravo/erpCommon/ad_actionButton/CreateFrom_Invoice_data.xsql |  6 
+++++-
 1 files changed, 5 insertions(+), 1 deletions(-)

diffs (16 lines):

diff -r 24f60c5e9ff5 -r f641668debc0 
src/org/openbravo/erpCommon/ad_actionButton/CreateFrom_Invoice_data.xsql
--- a/src/org/openbravo/erpCommon/ad_actionButton/CreateFrom_Invoice_data.xsql  
Wed Aug 25 13:14:06 2010 +0200
+++ b/src/org/openbravo/erpCommon/ad_actionButton/CreateFrom_Invoice_data.xsql  
Thu Aug 26 11:05:47 2010 +0530
@@ -358,7 +358,11 @@
         AND s.C_BPartner_ID = ?  
         AND EXISTS (SELECT 1 FROM M_INOUTLINE l 
         WHERE l.M_INOUT_ID = s.M_INOUT_ID 
-        AND l.isinvoiced = 'N') 
+        AND l.isinvoiced = 'N')
+        AND NOT EXISTS (SELECT 1 FROM C_INVOICE_CANDIDATE_V ic, C_ORDER o 
+        WHERE o.C_ORDER_ID = s.C_ORDER_ID
+        AND o.C_ORDER_ID = ic.C_ORDER_ID
+        AND ic.term = 'N') 
         ORDER BY NAME
       ]]>
     </Sql>

------------------------------------------------------------------------------
Sell apps to millions through the Intel(R) Atom(Tm) Developer Program
Be part of this innovative community and reach millions of netbook users 
worldwide. Take advantage of special opportunities to increase revenue and 
speed time-to-market. Join now, and jumpstart your future.
http://p.sf.net/sfu/intel-atom-d2d
_______________________________________________
Openbravo-commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/openbravo-commits

Reply via email to