Bug 9067

Summary: Staging an authority file gives conflicting messages
Product: Koha Reporter: Magnus Enger <magnus>
Component: MARC Authority data supportAssignee: Jonathan Druart <jonathan.druart>
Status: CLOSED FIXED QA Contact:
Severity: normal    
Priority: P5 - low CC: jonathan.druart, katrin.fischer, mtompset, tomascohen
Version: Main   
Hardware: All   
OS: All   
See Also: http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10097
Change sponsored?: --- Patch complexity: Small patch
Documentation contact: Documentation submission:
Text to go in the release notes:
Version(s) released in:
Attachments: Managing a staged authority file
Bug 9067: Hide item related strings when importing staged authority records
Sample 1 record authority MRC file.
Bug 9067: Hide item related strings when importing staged authority records
Bug 9067 - Fix space
Bug 9067: Hide item related strings when importing staged authority records
Bug 9067 - Fix space
[PASSED QA] Bug 9067: Hide item related strings when importing staged authority records
[PASSED QA] Bug 9067 - Fix space
Bug 9067: Hide item related strings when importing staged authority records
Bug 9067 - Fix space

Description Magnus Enger 2012-11-13 09:09:40 UTC
Created attachment 13417 [details]
Managing a staged authority file

After uploading a MARC file on "Home › Tools › Stage MARC records for import" it is possible to choose "Authority" as the "Record type". Doing this hides the "Check for embedded item record data?" question correctly. 

However, after clicking on "Stage for import", the list of feedback includes "0 item records found and staged". 

After clicking on the "Manage staged records" link on that same screen, the new screen that appears includes an option for "Item processing" as well as the text "Add new bibliographic records into this framework:" followed by a dropdown containing the bibliographic frameworks. See attached screenshot. 

I tried staging/importing an example file from another bug, and it did get imported OK, so this problem might be mostly cosmetic.
Comment 1 Katrin Fischer 2013-10-03 19:16:20 UTC
This is still true for managing staged imports on current master: item options are offered and displayed in the summary.
Comment 2 Jonathan Druart 2015-04-01 11:32:14 UTC Comment hidden (obsolete)
Comment 3 Jonathan Druart 2015-04-01 11:33:21 UTC
(In reply to Magnus Enger from comment #0)
> the text "Add new bibliographic records into this framework:" followed by a
> dropdown containing the bibliographic frameworks. See attached screenshot. 

This has been done by bug 10097.
Comment 4 Mark Tompsett 2015-04-11 05:43:55 UTC
Comment on attachment 37416 [details] [review]
Bug 9067:  Hide item related strings when importing staged authority records

Review of attachment 37416 [details] [review]:
-----------------------------------------------------------------

::: koha-tmpl/intranet-tmpl/prog/en/modules/tools/manage-marc-import.tt
@@ +306,5 @@
>              [% END %]
>          [% END %]
>      </li>
> +
> +    [% IF ( record_type == 'biblio' ) %]

You missed the section around line 378:
Number of items added	0
Number of items replaced	0
Number of items ignored because of duplicate barcode	0
Comment 5 Mark Tompsett 2015-04-11 05:46:11 UTC
Changing to Failed QA, simply because of the block of item counts was displayed:

Number of items added	0
Number of items replaced	0
Number of items ignored because of duplicate barcode	0

while viewing .../cgi-bin/koha/tools/manage-marc-import.pl
Everything else looked great. Just fix that tiny piece.
Comment 6 Mark Tompsett 2015-04-11 05:47:27 UTC
Created attachment 37674 [details]
Sample 1 record authority MRC file.

Attaching sample authority record that I used for testing.
Comment 7 Jonathan Druart 2015-04-13 08:20:03 UTC Comment hidden (obsolete)
Comment 8 Mark Tompsett 2015-04-25 15:43:14 UTC
Comment on attachment 37713 [details] [review]
Bug 9067: Hide item related strings when importing staged authority records

Review of attachment 37713 [details] [review]:
-----------------------------------------------------------------

::: koha-tmpl/intranet-tmpl/prog/en/modules/tools/manage-marc-import.tt
@@ +378,5 @@
> +  [% IF ( record_type == 'biblio' ) %]
> +      <tr><td>Number of items added</td><td>[% num_items_added %]</td></tr>
> +      <tr><td>Number of items replaced</td><td>[% num_items_replaced %]</td></tr>
> +      <tr><td>Number of items ignored because of duplicate barcode</td><td>[% num_items_errored %]</td></tr>
> +  [ % END %]

Tiny spacing issue. Fixing and signing off.
Comment 9 Mark Tompsett 2015-04-25 15:46:59 UTC Comment hidden (obsolete)
Comment 10 Mark Tompsett 2015-04-25 15:47:40 UTC Comment hidden (obsolete)
Comment 11 Mark Tompsett 2015-04-25 15:47:46 UTC Comment hidden (obsolete)
Comment 12 Katrin Fischer 2015-04-29 05:43:20 UTC Comment hidden (obsolete)
Comment 13 Katrin Fischer 2015-04-29 05:43:34 UTC Comment hidden (obsolete)
Comment 14 Tomás Cohen Arazi 2015-05-14 14:39:57 UTC
Please rebase for inclusion ASAP.
Comment 15 Mark Tompsett 2015-05-14 15:14:06 UTC
Created attachment 39188 [details] [review]
Bug 9067: Hide item related strings when importing staged authority records

On importing authority records, the items related string should not be
displayed.

Test plan:
1/ Import an authority record
2/ Confirm the item related string are not displayed.
3/ Before this script, the record_type param was lost just after
importing the records. Now you should see
"Processing authority records" of "Processing bibliographic records" in
the "MARC staging results"
4/ Revert the import and check there is not item related strings.

No behavior should exist on importing bibliographic records.

Signed-off-by: Mark Tompsett <mtompset@hotmail.com>

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Comment 16 Mark Tompsett 2015-05-14 15:14:11 UTC
Created attachment 39189 [details] [review]
Bug 9067 - Fix space

There was a [ % END %] which triggered template parsing errors.
Follow the test plan in comment #7 with both patches applied.

Signed-off-by: Mark Tompsett <mtompset@hotmail.com>

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Comment 17 Mark Tompsett 2015-05-14 15:19:21 UTC
Fixed conflict, retested, reset back to Passed QA.
(*grumbles about commas and white space making things conflict so easily*)
Comment 18 Tomás Cohen Arazi 2015-05-14 15:38:15 UTC
Patches pushed to master.

Thanks Jonathan and Mark!