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

SF.net SVN: ledger-smb:[5889] branches/1.3



Revision: 5889
          http://sourceforge.net/p/ledger-smb/code/5889
Author:   einhverfr
Date:     2013-06-04 10:16:31 +0000 (Tue, 04 Jun 2013)
Log Message:
-----------
Fixing 837, per customer default payment accounts not honored on payment dropdowns

Modified Paths:
--------------
    branches/1.3/Changelog
    branches/1.3/LedgerSMB/AA.pm
    branches/1.3/bin/aa.pl
    branches/1.3/bin/ir.pl
    branches/1.3/bin/is.pl

Modified: branches/1.3/Changelog
===================================================================
--- branches/1.3/Changelog	2013-06-04 10:13:53 UTC (rev 5888)
+++ branches/1.3/Changelog	2013-06-04 10:16:31 UTC (rev 5889)
@@ -5,6 +5,7 @@
 Changelog for 1.3.34
 * Fixed some SQL syntax issues on using overpayments (Chris T)
 * Fixed date range when clicking through income statement to gl (Chris T, 836)
+* Fixed invoice screens not recognizing default payment account (Chris T, 837)
 
 Changelog for 1.3.33
 * Fixed <?lsmb YYMMMDD ?> interpolation in settings (Chris T)

Modified: branches/1.3/LedgerSMB/AA.pm
===================================================================
--- branches/1.3/LedgerSMB/AA.pm	2013-06-04 10:13:53 UTC (rev 5888)
+++ branches/1.3/LedgerSMB/AA.pm	2013-06-04 10:16:31 UTC (rev 5889)
@@ -1301,9 +1301,11 @@
 			  b.discount AS tradediscount, 
 		          b.description AS business, 
 			  entity.control_code as entity_control_code,
-			  c.meta_number, ecl.*, ctf.default_reportable
+			  c.meta_number, ecl.*, ctf.default_reportable,
+                          c.cash_account_id, ca.accno as cash_accno
 		     FROM entity_credit_account c
 		     JOIN entity ON (entity.id = c.entity_id)
+                LEFT JOIN account ca ON c.cash_account_id = ca.id
 		LEFT JOIN business b ON (b.id = c.business_id)
                 LEFT JOIN country_tax_form ctf ON ctf.id = c.taxform_id
                 LEFT JOIN (SELECT coalesce(line_one, '')

Modified: branches/1.3/bin/aa.pl
===================================================================
--- branches/1.3/bin/aa.pl	2013-06-04 10:13:53 UTC (rev 5888)
+++ branches/1.3/bin/aa.pl	2013-06-04 10:16:31 UTC (rev 5889)
@@ -854,6 +854,8 @@
         </tr>
 ";
 
+    $form->{"select$form->{ARAP}_paid"} =~ /($form->{cash_accno}--[^<]*)/;
+    $form->{"$form->{ARAP}_paid_$form->{paidaccounts}"} = $1;
     $form->{paidaccounts}++ if ( $form->{"paid_$form->{paidaccounts}"} );
     for $i ( 1 .. $form->{paidaccounts} ) {
 

Modified: branches/1.3/bin/ir.pl
===================================================================
--- branches/1.3/bin/ir.pl	2013-06-04 10:13:53 UTC (rev 5888)
+++ branches/1.3/bin/ir.pl	2013-06-04 10:16:31 UTC (rev 5889)
@@ -786,6 +786,8 @@
 	</tr>
 |;
 
+    $form->{"selectAP_paid"} =~ /($form->{cash_accno}--[^<]*)/;
+    $form->{"AP_paid_$form->{paidaccounts}"} = $1;
     $form->{paidaccounts}++ if ( $form->{"paid_$form->{paidaccounts}"} );
     for $i ( 1 .. $form->{paidaccounts} ) {
 

Modified: branches/1.3/bin/is.pl
===================================================================
--- branches/1.3/bin/is.pl	2013-06-04 10:13:53 UTC (rev 5888)
+++ branches/1.3/bin/is.pl	2013-06-04 10:16:31 UTC (rev 5889)
@@ -863,7 +863,8 @@
     print "
         </tr>
 ";
-
+    $form->{"selectAR_paid"} =~ /($form->{cash_accno}--[^<]*)/;
+    $form->{"AR_paid_$form->{paidaccounts}"} = $1;
     $form->{paidaccounts}++ if ( $form->{"paid_$form->{paidaccounts}"} );
     for $i ( 1 .. $form->{paidaccounts} ) {
 

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