summaryrefslogtreecommitdiff
path: root/bin
diff options
context:
space:
mode:
authoreinhverfr <einhverfr@4979c152-3d1c-0410-bac9-87ea11338e46>2008-10-20 01:05:26 +0000
committereinhverfr <einhverfr@4979c152-3d1c-0410-bac9-87ea11338e46>2008-10-20 01:05:26 +0000
commit70c29cebc700cf9cd2f63b0a333b61aca85ac30d (patch)
tree81ad8b8abc6a572f80a073388298acb941db7696 /bin
parentf084ce511dbdda4fcb65c6f64746c201cc5f2caa (diff)
Removing references to ca.pl's list_transactions function and moving these to a gl report.
git-svn-id: https://ledger-smb.svn.sourceforge.net/svnroot/ledger-smb/trunk@2374 4979c152-3d1c-0410-bac9-87ea11338e46
Diffstat (limited to 'bin')
-rw-r--r--bin/gl.pl9
-rw-r--r--bin/rp.pl6
2 files changed, 11 insertions, 4 deletions
diff --git a/bin/gl.pl b/bin/gl.pl
index 9a0d8572..95e9a438 100644
--- a/bin/gl.pl
+++ b/bin/gl.pl
@@ -403,6 +403,11 @@ qq|<input name="l_description" class=checkbox type=checkbox value=Y checked> |
. $locale->text('Subtotal')
. qq|</td>
</tr>
+ <tr>
+ <td nowrap><input name="l_balance" class=checkbox type=checkbox value=Y> |
+ . $locale->text('Balance')
+ . qq|</td>
+ </tr>
</table>
</tr>
</table>
@@ -478,7 +483,7 @@ sub generate_report {
$ml = ( $form->{category} =~ /(A|E)/ ) ? -1 : 1;
- unless ( $form->{category} eq 'X' ) {
+ if (defined $form->{category} and $form->{category} ne 'X' ) {
$form->{title} .=
" : " . $locale->text( $acctype{ $form->{category} } );
}
@@ -590,7 +595,7 @@ sub generate_report {
$form->{l_cleared} = "Y";
}
- if ( $form->{accno} || $form->{gifi_accno} ) {
+ if ( $form->{chart_id} || $form->{gifi_accno} ) {
@columns = grep !/(accno|gifi_accno)/, @columns;
push @columns, "balance";
$form->{l_balance} = "Y";
diff --git a/bin/rp.pl b/bin/rp.pl
index 1426824e..257a6bb2 100644
--- a/bin/rp.pl
+++ b/bin/rp.pl
@@ -715,8 +715,10 @@ sub list_accounts {
my %column_data;
my $description = $form->escape( $ref->{description} );
+ # gl.pl requires datefrom instead of fromdate, etc. We will get this
+ # consistent.... eventually.... --CT
my $href =
-qq|ca.pl?path=$form->{path}&action=list_transactions&accounttype=$form->{accounttype}&login=$form->{login}&sessionid=$form->{sessionid}&fromdate=$form->{fromdate}&todate=$form->{todate}&sort=transdate&l_heading=$form->{l_heading}&l_subtotal=$form->{l_subtotal}&department=$department&projectnumber=$projectnumber&project_id=$form->{project_id}&title=$title&nextsub=$form->{nextsub}&prevreport=$form->{callback}|;
+qq|gl.pl?path=$form->{path}&action=generate_report&accounttype=$form->{accounttype}&datefrom=$form->{fromdate}&dateto=$form->{todate}&sort=transdate&l_heading=$form->{l_heading}&l_subtotal=$form->{l_subtotal}&l_balance=Y&department=$department&projectnumber=$projectnumber&project_id=$form->{project_id}&title=$title&nextsub=$form->{nextsub}&prevreport=$form->{callback}&category=X&l_reference=Y&l_transdate=Y&l_description=Y&l_debit=Y&l_credit=Y|;
if ( $form->{accounttype} eq 'gifi' ) {
$href .= "&gifi_accno=$ref->{accno}&gifi_description=$description";
@@ -726,7 +728,7 @@ qq|ca.pl?path=$form->{path}&action=list_transactions&accounttype=$form->{account
}
}
else {
- $href .= "&accno=$ref->{accno}&description=$description";
+ $href .= "&accno=$ref->{accno}";
}
$ml = ( $ref->{category} =~ /(A|E)/ ) ? -1 : 1;