Option causes the final EDI to be printed to STDOUT, but does not
populate any data in the DB nor does it FTP the file to the vendor.
Signed-off-by: Bill Erickson <berick@esilibrary.com>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
my %defaults = (
'quiet' => 0,
'test' => 0, # TODO
- 'max-batch-size=i' => -1
+ 'max-batch-size=i' => -1,
+
+ # if true, print final EDI to STDOUT, send nothign to the vendor, write nothing to the DB
+ 'debug-only' => 0
);
my $cs = OpenILS::Utils::Cronscript->new(\%defaults);
# than to add a cascade of failing inscrutable copies of the same message(s) to our DB.
}
+ if ($opts->{'debug-only'}) {
+ print OpenILS::Application::Acq::EDI->attempt_translation($message, 1)->edi . "\n";
+ print "\ndebug-only => skipping FTP\n";
+ next;
+ }
+
print "Writing new message + translation to DB for $logstr2\n";
$e->xact_begin;