[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

SF.net SVN: ledger-smb:[6255] addons/1.3/wxPOS/setup/functions.sql

Revision: 6255
Author:   einhverfr
Date:     2013-11-08 05:13:33 +0000 (Fri, 08 Nov 2013)
Log Message:
Handling temporary sales properly

Modified Paths:

Modified: addons/1.3/wxPOS/setup/functions.sql
--- addons/1.3/wxPOS/setup/functions.sql	2013-11-08 05:10:36 UTC (rev 6254)
+++ addons/1.3/wxPOS/setup/functions.sql	2013-11-08 05:13:33 UTC (rev 6255)
@@ -57,9 +57,10 @@
        (validfrom is null OR validfrom >= now()) AND
        (validto IS NULL OR validto <= now())
-SELECT p.parts_id, p.credit_id, p.pricebreak, p.sellprice
+SELECT p.parts_id, c.id, p.pricebreak, p.sellprice
   FROM partscustomer p
- WHERE credit_id is null and pricegroup_id is null AND
+  JOIN entity_credit_account c ON (c.entity_class = 1)
+ WHERE credit_id is null and p.pricegroup_id is null AND
        (validfrom is null OR validfrom >= now()) AND
        (validto IS NULL OR validto <= now())

This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.

November Webinars for C, C++, Fortran Developers
Accelerate application performance with scalable programming models. Explore
techniques for threading, error checking, porting, and tuning. Get the most 
from the latest Intel processors and coprocessors. See abstracts and register
Ledger-smb-commits mailing list