Bug 17072 - 006 not filling in with existing values
Summary: 006 not filling in with existing values
Status: CLOSED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: Cataloging (show other bugs)
Version: master
Hardware: All All
: P5 - low major (vote)
Assignee: Jacek Ablewicz
QA Contact: Testopia
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-08-07 09:11 UTC by Katrin Fischer
Modified: 2019-06-27 09:24 UTC (History)
8 users (show)

See Also:
Change sponsored?: ---
Patch complexity: Trivial patch
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:


Attachments
Bug 17072 - 006 not filling in with existing values (3.23 KB, patch)
2016-09-01 16:22 UTC, Jacek Ablewicz
Details | Diff | Splinter Review
[SIGNED-OFF]Bug 17072: 006 not filling in with existing values (3.32 KB, patch)
2016-09-05 19:43 UTC, Héctor Eduardo Castro Avalos
Details | Diff | Splinter Review
Bug 17072: 006 not filling in with existing values (3.38 KB, patch)
2016-09-07 14:49 UTC, Jonathan Druart
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Katrin Fischer 2016-08-07 09:11:48 UTC
Moved out from bug 10148:

When you use the 006 builder to view the existing values in the 006 tag, Koha is not pulling these existing values into the builder window. Instead, Koha appears to be using defaults.

For example:

1. Open a record in the editor
2. Switch from BKS to another material type.
3. Change as many settings as possible.
4. Close plugin.
5. Reopen plugin - notice your selections are not shown.
Comment 1 Jacek Ablewicz 2016-09-01 16:22:24 UTC Comment hidden (obsolete)
Comment 2 Héctor Eduardo Castro Avalos 2016-09-05 19:43:13 UTC Comment hidden (obsolete)
Comment 3 Jonathan Druart 2016-09-07 11:48:46 UTC
Why don't you use the same mapping as from bug 9093?
Would not it be worth putting that mapping in a centralized place?
Comment 4 Jacek Ablewicz 2016-09-07 14:36:56 UTC
(In reply to Jonathan Druart from comment #3)

> Why don't you use the same mapping as from bug 9093?
> Would not it be worth putting that mapping in a centralized place?

I considered for a moment (albeit a very brief one) putting this code into some kind of subroutine which would handle both kinds of mappings for 006 and 008, but:

- the mapping is pretty similar, but not identical (t, a, s)
- AFAIK this could be reusable only in the MARC21 006 and 008 plugins
- would have to add a pod section, unit tests (bleh) etc. for this sub - total amount of lines added will be probably 2x more then the now existing code in 008 and 006 combined
- test plan and the bug description would require significantly more work than a simple copy & paste ;)
Comment 5 Jonathan Druart 2016-09-07 14:49:01 UTC
Created attachment 55303 [details] [review]
Bug 17072: 006 not filling in with existing values

When you use the 006 builder to view the existing values in the 006
tag, Koha is not pulling these existing values into the builder
window. Instead, Koha appears to be using defaults.

To reproduce:

1. Open a record in the editor
2. Switch from BKS to another material type.
3. Change as many settings as possible.
4. Close plugin.
5. Reopen plugin - notice your selections are not shown.

Trivial patch, heavilly inspired by Bug 9093.

To test:

1. Apply patch
2. Ensure that issue described above is no longer reproductible

Signed-off-by: Hector Castro <hector.hecaxmmx@gmail.com>
Works as advertised

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Comment 6 Kyle M Hall 2016-09-08 12:58:12 UTC
Pushed to master for 16.11, thanks Jacek!
Comment 7 Frédéric Demians 2016-09-08 20:11:27 UTC
Pushed in 16.05. Will be in 16.05.04.
Comment 8 Julian Maurice 2016-09-16 08:32:20 UTC
Pushed to 3.22.x, will be in 3.22.11