Bug 26402: Add --framework parameter to commit_file.pl
authorAndreas Jonsson <andreas.jonsson@kreablo.se>
Mon, 7 Sep 2020 09:31:58 +0000 (09:31 +0000)
committerJonathan Druart <jonathan.druart@bugs.koha-community.org>
Wed, 3 Nov 2021 14:40:52 +0000 (15:40 +0100)
commit8605082a782af2c00bf735e32fd711a67ad78e01
treeafd5a42ee1e0c8c3d504c4116c4a8f4b9ef37c24
parente44b4837f58fe22fa2010cceffac0fa0171277fc
Bug 26402: Add --framework parameter to commit_file.pl

This patch adds the option to pass a frameworkcode to the commit_file.pl
script.

To test:
1. Stage a MARC file using stage_file.pl.  For instance using the devbox:

   cd ~/kohaclone
   sudo koha-shell -c 'perl misc/stage_file.pl --file t/db_dependent/www/data/marc21record.mrc' kohadev

2. Note the assigned batch number and commit the batch using --framework parameter to commit_file.pl.  For example using the devbox:

   sudo koha-shell -c 'perl misc/commit_file.pl --batch-number 1 --framework ACQ' kohadev

3. Verify that the framework code was correctly assigned:

   sudo koha-mysql kohadev -e 'SELECT frameworkcode FROM biblio ORDER BY timestamp DESC LIMIT 1;'
=> SUCCESS: It picked it

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
misc/commit_file.pl