[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
SF.net SVN: ledger-smb:[4271] branches/1.3
- Subject: SF.net SVN: ledger-smb:[4271] branches/1.3
- From: ..hidden..
- Date: Fri, 20 Jan 2012 12:57:50 +0000
Revision: 4271
http://ledger-smb.svn.sourceforge.net/ledger-smb/?rev=4271&view=rev
Author: einhverfr
Date: 2012-01-20 12:57:49 +0000 (Fri, 20 Jan 2012)
Log Message:
-----------
Added a bank register mode for drill downs from chart of accounts. This swaps debits/credits in display to match bank statements.
Fixed join projection in draft__search due to account.id and account_heading.id conflicts.
Modified Paths:
--------------
branches/1.3/Changelog
branches/1.3/UI/ca-list-selector.html
branches/1.3/bin/gl.pl
branches/1.3/sql/modules/Drafts.sql
Modified: branches/1.3/Changelog
===================================================================
--- branches/1.3/Changelog 2012-01-20 10:51:40 UTC (rev 4270)
+++ branches/1.3/Changelog 2012-01-20 12:57:49 UTC (rev 4271)
@@ -7,6 +7,8 @@
* Fixed handling of non-existing roles in menu grants (Chris T)
* Added reverse_bank_recs setting for those that want to
do recs from bank perspective (Chris T)
+* Added "bank register mode" for account transaction lists (Chris T)
+* Fixed join projection issue in draft search routine (Chris T)
Changelog for 1.3.10
* Fixes for permissions for exchangerate table (Erik H)
Modified: branches/1.3/UI/ca-list-selector.html
===================================================================
--- branches/1.3/UI/ca-list-selector.html 2012-01-20 10:51:40 UTC (rev 4270)
+++ branches/1.3/UI/ca-list-selector.html 2012-01-20 12:57:49 UTC (rev 4271)
@@ -33,6 +33,17 @@
<th align="right"><?lsmb text('To') ?></th>
<td><?lsmb PROCESS input element_data={class => 'date', name => 'dateto' size => '11', title="yyyy-mm-dd"} ?></td>
</tr>
+ <tr>
+ <th align="right" colspan="1"><?lsmb text('Bank Register Mode') ?>
+ </th>
+ <td colspan="1" align="left">
+ <select name="bank_register_mode">
+ <option value="0"><?lsmb text('No') ?></option>
+ <option value="1"><?lsmb text('Yes') ?></option>
+ </select>
+ </td>
+ <td colspan=2>(<?lsmb text('Swaps debits and credits to match bank statements') ?>)</td>
+ </tr>
<?lsmb IF form.all_department ?>
<tr>
Modified: branches/1.3/bin/gl.pl
===================================================================
--- branches/1.3/bin/gl.pl 2012-01-20 10:51:40 UTC (rev 4270)
+++ branches/1.3/bin/gl.pl 2012-01-20 12:57:49 UTC (rev 4271)
@@ -633,11 +633,16 @@
push @options, $locale->text('Amount') . " <= $option";
}
}
-
@columns =
$form->sort_columns(
qw(transdate id reference description notes source memo debit credit accno gifi_accno department)
);
+ if ($form->{bank_register_mode}){
+ @columns = $form->sort_columns(
+ qw(transdate id reference description notes source memo credit debit accno
+ gifi_accno department)
+ );
+ }
pop @columns if $form->{department};
if ( $form->{link} =~ /_paid/ ) {
@@ -645,6 +650,12 @@
$form->sort_columns(
qw(transdate id reference description notes source memo cleared debit credit accno gifi_accno)
);
+ if ($form->{bank_register_mode}){
+ @columns = $form->sort_columns(
+ qw(transdate id reference description notes source memo cleared credit
+ debit credit accno gifi_accno)
+ );
+ }
$form->{l_cleared} = "Y";
}
@@ -691,6 +702,10 @@
balance => 'Balance',
cleared => 'R'
};
+ if ($form->{bank_register_mode}){
+ $column_names->{credit} = 'Debit';
+ $column_names->{debit} = 'Credit';
+ }
my $sort_href = "$href&sort";
my @sort_columns = qw(id transdate reference source memo description department accno gifi_accno);
Modified: branches/1.3/sql/modules/Drafts.sql
===================================================================
--- branches/1.3/sql/modules/Drafts.sql 2012-01-20 10:51:40 UTC (rev 4270)
+++ branches/1.3/sql/modules/Drafts.sql 2012-01-20 12:57:49 UTC (rev 4271)
@@ -40,7 +40,7 @@
WHERE lower(in_type) = 'ar'
) trans
JOIN acc_trans line ON (trans.id = line.trans_id)
- JOIN chart ON (line.chart_id = chart.id)
+ JOIN chart ON (line.chart_id = chart.id and charttype = 'A')
LEFT JOIN voucher v ON (v.trans_id = trans.id)
WHERE (in_from_date IS NULL or trans.transdate >= in_from_date)
AND (in_to_date IS NULL
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.