]> wagnertech.de Git - mfinanz.git/blobdiff - SL/RP.pm
Bug 1797 - cb_transaction nicht eindeutig bei GuV
[mfinanz.git] / SL / RP.pm
index f98d47561b002ce250850a4a24b0b9ef28c1a39a..d371912843c3a90b65756ce9c975f0d61dd32247 100644 (file)
--- a/SL/RP.pm
+++ b/SL/RP.pm
@@ -211,6 +211,13 @@ sub get_accounts {
 
   $sth->finish;
 
+  # if l_ob is selected l_cb is always ignored
+  if ( $form->{l_ob} ) {
+    $where .= ' AND ac.ob_transaction is true  ' 
+  } elsif ( not $form->{l_cb} ) {
+    $where .= ' AND ac.cb_transaction is false ';
+  };
+
   if ($fromdate) {
     $fromdate = conv_dateq($fromdate);
     if ($form->{method} eq 'cash') {
@@ -464,6 +471,8 @@ sub get_accounts_g {
   my $inwhere = "";
   my $item;
 
+  $where .= ' AND ac.cb_transaction is false ' unless $form->{l_cb};
+
   if ($fromdate) {
     $fromdate = conv_dateq($fromdate);
     if ($form->{method} eq 'cash') {