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

SF.net SVN: ledger-smb: [1545] trunk/LedgerSMB/CP.pm



Revision: 1545
          http://ledger-smb.svn.sourceforge.net/ledger-smb/?rev=1545&view=rev
Author:   einhverfr
Date:     2007-09-07 22:25:46 -0700 (Fri, 07 Sep 2007)

Log Message:
-----------
Correcting more breakage on entity stuff

Modified Paths:
--------------
    trunk/LedgerSMB/CP.pm

Modified: trunk/LedgerSMB/CP.pm
===================================================================
--- trunk/LedgerSMB/CP.pm	2007-09-08 05:11:46 UTC (rev 1544)
+++ trunk/LedgerSMB/CP.pm	2007-09-08 05:25:46 UTC (rev 1545)
@@ -215,7 +215,7 @@
     my $dbh = $form->{dbh};
 
     $vc_id = $dbh->quote( $form->{"entity_id"} );
-    my $where = qq|WHERE a.entity__id = $vc_id
+    my $where = qq|WHERE a.entity_id = $vc_id
 					 AND a.amount != a.paid|;
 
     $curr = $dbh->quote( $form->{currency} );
@@ -257,9 +257,10 @@
     }
 
     my $query = qq|SELECT a.id, a.invnumber, a.transdate, a.amount, a.paid,
-						  a.curr, c.name, a.entity_id, c.language_code
+						  a.curr, e.name, a.entity_id, c.language_code
 					 FROM $form->{arap} a
 					 JOIN $form->{vc} c ON (c.entity_id = a.entity_id)
+					 JOIN entity e ON (a.entity_id = e.id)
 				   $where
 				 ORDER BY $sortorder|;
 


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