when reverting import batch: don't try to delete items that are already deleted
authorGalen Charlton <galen.charlton@liblime.com>
Mon, 12 Nov 2007 23:13:44 +0000 (17:13 -0600)
committerJoshua Ferraro <jmf@liblime.com>
Tue, 13 Nov 2007 00:32:24 +0000 (18:32 -0600)
Signed-off-by: Chris Cormack <crc@liblime.com>
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
C4/ImportBatch.pm

index e17bc65..05dae67 100644 (file)
@@ -596,6 +596,7 @@ sub BatchRevertItems {
 
     my $sth = $dbh->prepare_cached("SELECT import_items_id, itemnumber
                                    FROM import_items
+                                   JOIN items USING (itemnumber)
                                    WHERE import_record_id = ?");
     $sth->bind_param(1, $import_record_id);
     $sth->execute();