X-Git-Url: http://wagnertech.de/gitweb/gitweb.cgi/mfinanz.git/blobdiff_plain/5eb991fafe1bd823ece8b46728cf39209b787ab1..552b1b8ba168cda80a7cedf40dcb950c1b11381a:/SL/BackgroundJob/SelfTest/Transactions.pm diff --git a/SL/BackgroundJob/SelfTest/Transactions.pm b/SL/BackgroundJob/SelfTest/Transactions.pm index 667213d4b..eedbbee20 100644 --- a/SL/BackgroundJob/SelfTest/Transactions.pm +++ b/SL/BackgroundJob/SelfTest/Transactions.pm @@ -136,9 +136,15 @@ sub check_verwaiste_invoice_eintraege { my ($self) = @_; my $query = qq| select * from invoice i - where trans_id not in (select id from ar union select id from ap order by id) |; + where trans_id not in (select id from ar WHERE ar.transdate >=? AND ar.transdate <=? + UNION + select id from ap WHERE ap.transdate >= ? and ap.transdate <= ?) + AND i.transdate >=? AND i.transdate <=?|; + + my $verwaiste_invoice = selectall_hashref_query($::form, $self->dbh, $query, $self->fromdate, $self->todate, + $self->fromdate, $self->todate, $self->fromdate, $self->todate); + - my $verwaiste_invoice = selectall_hashref_query($::form, $self->dbh, $query); if (@$verwaiste_invoice) { $self->tester->ok(0, "Es gibt verwaiste invoice Einträge! (wo ar/ap-Eintrag fehlt)"); for my $invoice ( @{ $verwaiste_invoice }) {