X-Git-Url: http://wagnertech.de/gitweb/gitweb.cgi/mfinanz.git/blobdiff_plain/c35e1e2fb21b8cff496188f80eec919367262618..e1cb00366d40cc3a1b07e065b51ad39c84baf7e6:/SL/DO.pm diff --git a/SL/DO.pm b/SL/DO.pm index 5f8ab5227..48baa7a87 100644 --- a/SL/DO.pm +++ b/SL/DO.pm @@ -109,7 +109,8 @@ sub transactions { push @values, '%' . $form->{$item} . '%'; } - if (!($form->{open} && $form->{closed})) { + if (($form->{open} || $form->{closed}) && + ($form->{open} ne $form->{closed})) { push @where, ($form->{open} ? "NOT " : "") . "COALESCE(dord.closed, FALSE)"; } @@ -659,7 +660,7 @@ sub retrieve { doi.reqdate, doi.project_id, doi.serialnumber, doi.lastcost, doi.ordnumber, doi.transdate, doi.cusordnumber, doi.longdescription, doi.price_factor_id, doi.price_factor, doi.marge_price_factor, - pr.projectnumber, + pr.projectnumber, dord.transdate AS dord_transdate, pg.partsgroup FROM delivery_order_items doi JOIN parts p ON (doi.parts_id = p.id)