X-Git-Url: http://wagnertech.de/git?a=blobdiff_plain;f=SL%2FAR.pm;h=adffeb6bc677cb7d132919789c3348965c559196;hb=2a3bcd6e2e1adee31dff01f4f18086a536998a3c;hp=b6a7376e1409740fb29e51a109aa642a0b9b88c2;hpb=61cdba5d566357f3beabe0e7f3f0cb2d7bdccd73;p=kivitendo-erp.git diff --git a/SL/AR.pm b/SL/AR.pm index b6a7376e1..adffeb6bc 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 ( $::auth->assert('show_ar_transactions', 1) ) { + $where .= " AND NOT invoice = 'f' "; # remove ar transactions from Sales -> Reports -> Invoices + }; + if ($form->{customernumber}) { $where .= " AND c.customernumber = ?"; push(@values, $form->{customernumber});