X-Git-Url: http://wagnertech.de/gitweb/gitweb.cgi/mfinanz.git/blobdiff_plain/96aa70a1194b80a97b82ab8479fec86cd6074d13..e8d91442a904758a2c15d5d22a05790fac120d23:/SL/AR.pm diff --git a/SL/AR.pm b/SL/AR.pm index b6a7376e1..d97c443d1 100644 --- a/SL/AR.pm +++ b/SL/AR.pm @@ -515,6 +515,11 @@ sub ar_transactions { qq|LEFT JOIN department d ON (d.id = a.department_id)|; my $where = "1 = 1"; + + unless ( $main::auth->check_right($form->{login}, 'show_ar_transactions') ) { + $where .= " AND NOT invoice = 'f' "; # remove ar transactions from Sales -> Reports -> Invoices + }; + if ($form->{customernumber}) { $where .= " AND c.customernumber = ?"; push(@values, $form->{customernumber});