Bug 11299: Add a button to the biblio edition page to automatically add authority...
authorBouzid Fergani <bouzid.fergani@inlibro.com>
Wed, 6 Nov 2013 15:49:09 +0000 (10:49 -0500)
committerJonathan Druart <jonathan.druart@bugs.koha-community.org>
Thu, 14 Jan 2021 13:03:49 +0000 (14:03 +0100)
commit11de34063970d7a74dc0541000287957b7790225
treee400f3bbf7f049f7a00ee216da491070eb668b09
parent6cd68dd05bdac2787fa0b67b7f90a5836c57745c
Bug 11299: Add a button to the biblio edition page to automatically add authority links in the current biblio record via AJAX. Also adds a button to easily create missing authority records.

 add authority type in the form to create the missing  authority.
 when authority was found, the 600$9 field have the authid.

Testing scenario (Creating an authority record for a failed automatic link) :

 1 - In your system preferences set:
    AutoCreateAuthorities: Don't generate
    BiblioAddsAuthorities: Allow
 2 - Go to the Cataloging -> New record (koha/cataloguing/addbiblio.pl)
    Ensure you are using the basic editor
 3 - Click the "Link authorities automatically" button.
    A message should appear, telling the user "No authority link was changed."
 4 - Add random informations in field 600$a of the biblio record.
 5 - Click the "Link authorities automatically" button.
   the message box should now show  "600 - No matching authority found.".
   the 9 subfield is red
   Above the 9 subfield is a red X with a blue plus next to it
   Hover on the plus, see it is titled 'Create authority'
 6 - Click the 'Create authority' link
 7 - A new authroity form pops up, the info from the cataloging editor is prefilled
     Click the 100 field heading to expand and confirm info is transferred
 8 - Fill in necessary fields and save the new authority
 9 - The cataloging screen now has the 9 subfield populated and is green
10 - Click "Link authorities automatically" again
     Dialog says "No authority link was changed"
11 - In another tab go to System preferences and set AutoCreateAuthorities to 'Generate'
12 - Add random information to the 650 field
13 - Click 'Link authorities' button
14 - Dialog says:650 - No matching authority found. A new authority was created automatically.
15 - The subfield 9 is green and has the id of the new authority record
16 - In another tab search authorities and find an existing subject heading
17 - Add a new 650 with the info from the existing record
18 - Click 'Link authorities'
19 - The new field is correctly linked to existing authority

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
https://bugs.koha-community.org/show_bug.cgi?id=12299
Signed-off-by: Michal Denar <black23@gmail.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Michal Denar <black23@gmail.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
13 files changed:
C4/Biblio.pm
authorities/authorities.pl
cataloguing/z3950_auth_search.pl
koha-tmpl/intranet-tmpl/prog/css/addbiblio.css
koha-tmpl/intranet-tmpl/prog/en/modules/authorities/authorities.tt
koha-tmpl/intranet-tmpl/prog/en/modules/authorities/blinddetail-biblio-search.tt
koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/addbiblio.tt
koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/z3950_auth_search.tt
koha-tmpl/intranet-tmpl/prog/js/cataloging.js
koha-tmpl/intranet-tmpl/prog/js/z3950_search.js
svc/cataloguing/automatic_linker.pl [new file with mode: 0755]
t/Biblio.t
t/db_dependent/Biblio.t