]> wagnertech.de Git - mfinanz.git/blobdiff - SL/DO.pm
Recht zum Einsehen von Einkaufsdokumenten aller Mitarbeiter anwenden
[mfinanz.git] / SL / DO.pm
index 54df47ca70d7ddb3c34c6a0317b9e039220d8f62..ecaee496d85f1618bcfc76b6fc4ac3cc28033a8a 100644 (file)
--- a/SL/DO.pm
+++ b/SL/DO.pm
@@ -129,7 +129,7 @@ sub transactions {
     push @where, "dord.$item = ?";
     push @values, conv_i($form->{$item});
   }
-  if (!$main::auth->assert('sales_all_edit', 1)) {
+  if ( !(($vc eq 'customer' && $main::auth->assert('sales_all_edit', 1)) || ($vc eq 'vendor' && $main::auth->assert('purchase_all_edit', 1))) ) {
     push @where, qq|dord.employee_id = (select id from employee where login= ?)|;
     push @values, $::myconfig{login};
   }