Revision 552b1b8b
Von Jan Büren vor mehr als 8 Jahren hinzugefügt
SL/BackgroundJob/SelfTest/Transactions.pm | ||
---|---|---|
136 | 136 |
my ($self) = @_; |
137 | 137 |
my $query = qq| |
138 | 138 |
select * from invoice i |
139 |
where trans_id not in (select id from ar union select id from ap order by id) |; |
|
139 |
where trans_id not in (select id from ar WHERE ar.transdate >=? AND ar.transdate <=? |
|
140 |
UNION |
|
141 |
select id from ap WHERE ap.transdate >= ? and ap.transdate <= ?) |
|
142 |
AND i.transdate >=? AND i.transdate <=?|; |
|
143 |
|
|
144 |
my $verwaiste_invoice = selectall_hashref_query($::form, $self->dbh, $query, $self->fromdate, $self->todate, |
|
145 |
$self->fromdate, $self->todate, $self->fromdate, $self->todate); |
|
146 |
|
|
140 | 147 |
|
141 |
my $verwaiste_invoice = selectall_hashref_query($::form, $self->dbh, $query); |
|
142 | 148 |
if (@$verwaiste_invoice) { |
143 | 149 |
$self->tester->ok(0, "Es gibt verwaiste invoice Einträge! (wo ar/ap-Eintrag fehlt)"); |
144 | 150 |
for my $invoice ( @{ $verwaiste_invoice }) { |
Auch abrufbar als: Unified diff
SelfTests: Verwaiste invoice-Einträge auch auf Zeitraum beschränken