Bug 10132: Add ability to set MARC Organization Code at library level
authorJosef Moravec <josef.moravec@gmail.com>
Sun, 11 Jun 2017 19:23:41 +0000 (19:23 +0000)
committerJonathan Druart <jonathan.druart@bugs.koha-community.org>
Tue, 19 Sep 2017 12:47:27 +0000 (09:47 -0300)
commitb36a0e1a59b92294cabe0ea33886f43f8ef1a5fe
tree518b952ca48468772c1950397214ab592a2ac6da
parente2d56c0b2b6b45af2926fe3c8b80c35868fb3738
Bug 10132: Add ability to set MARC Organization Code at library level

Test plan:
0. Apply patches
1. Update database
2. Go to administration -> libraries, try to update some library and
fill in some value into Marc Organization code field
3. Save this library and edit again - the code should be stored
correctly
4. Go to system preferences and fill in some value into MARCOrgCode
preference, note there is enhanced description mentioning the ability to
set organization code on library level
5. Set active library to the one with own org code stored
6. Go to cataloguing, create new empty record and click into field 003 -
there should be the code you filled for that library
7. Set active library to one withou marc org code
8. Go to cataloguing, create new empty record and click into field 003 -
there should be the code from system preference
9. Go to system preferences again and set AutoCreateAuthorities to
'generate' and BiblioAddsAuthorities to 'allow'
10. Go to cataloguing and create some biblio record, fill in any author
in to create its authority record, save the biblio
11. Go to authorities and find this created authority, go to details and
check the fields: 003, 040$a, 040$c, 670$a - there should be used right org code
12. prove t/db_dependent/AuthoritiesMarc.t t/db_dependent/Biblio.t t/db_dependent/Koha/Libraries.t

Signed-off-by: Hugo Agud <hagud@orex.es>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
C4/AuthoritiesMarc.pm
C4/Biblio.pm
Koha/Library.pm
cataloguing/value_builder/marc21_orgcode.pl