[Bug 43490] New: Advanced editor failing to load when 942$2 and 942$m missing values
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=43490 Bug ID: 43490 Summary: Advanced editor failing to load when 942$2 and 942$m missing values Initiative type: --- Sponsorship --- status: Product: Koha Version: unspecified Hardware: All OS: All Status: NEW Severity: minor Priority: P5 - low Component: Cataloging Assignee: koha-bugs@lists.koha-community.org Reporter: dcook@prosentient.com.au QA Contact: testopia@bugs.koha-community.org CC: m.de.rooy@rijksmuseum.nl Target Milestone: --- I don't know why but sometimes the advanced editor will fail to load and will throw this error: "Inserting collapsed marker partially overlapping an existing one" It seems to be when the 942$2 and 942$m are present in the MARC record but missing values. Somehow a default value of "ddc" gets generated for 942$2 and I can see 942$2 and 942$c widgets created but the Javascript seems to be doing some reiterative work and even though it's created the 942$c widget, it fails to detect it on a subsequent pass and the editor fails. -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=43490 --- Comment #1 from David Cook <dcook@prosentient.com.au> --- Created attachment 205297 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=205297&action=edit Console error -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=43490 --- Comment #2 from David Cook <dcook@prosentient.com.au> --- Hmm if I do a try/catch... and then get rid of the $m and try to backspace over the widget used by the $2 ddc... it throws the same error... Maybe it's the proximity of the $2 and $c widgets right next to each other... -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=43490 Phil Ringnalda <phil@chetcolibrary.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |phil@chetcolibrary.org -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=43490 David Cook <dcook@prosentient.com.au> changed: What |Removed |Added ---------------------------------------------------------------------------- Summary|Advanced editor failing to |Advanced editor not |load when 942$2 and 942$m |handling marcWidgetPrefill |missing values |correctly -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=43490 David Cook <dcook@prosentient.com.au> changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|koha-bugs@lists.koha-commun |dcook@prosentient.com.au |ity.org | -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=43490 --- Comment #3 from David Cook <dcook@prosentient.com.au> --- Created attachment 205401 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=205401&action=edit Problematic MARCXML record -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=43490 David Cook <dcook@prosentient.com.au> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |Needs Signoff -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=43490 --- Comment #4 from David Cook <dcook@prosentient.com.au> --- Created attachment 205402 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=205402&action=edit Bug 43490: Fix advanced editor widget marcWidgetPrefill This change fixes the marcWiedgetPrefill in the advanced editor so that it properly stops processing a line when it does a marcWidgetPrefill, so that the updated line gets actioned instead of the original line, which can have the wrong offsets in some situations (e.g. $2 empty gets prefilled to $2ddc which causes an issue for $cBK). Test plan: 0. Don't apply the patch yet 1. Import the attached "Problematic MARCXML record" 2. Enable the "EnableAdvancedCatalogingEditor" system preference 3. Edit the problematic record using the Advanced Editor 4. Note that the editor doesn't finish loading and you get a console error like "Uncaught Error: Inserting collapsed marker partially overlapping an existing one" 5. Apply the patch 6. Refresh the page with the advanced editor 7. Note that it now loads and the 942$2 has a widget that defaults to "Dewey Decimal Classification" and a 942$c widget that defaults to "Books" 8. Time to celebrate! -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=43490 David Cook <dcook@prosentient.com.au> changed: What |Removed |Added ---------------------------------------------------------------------------- Severity|minor |normal -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=43490 David Nind <david@davidnind.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Signed Off -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=43490 David Nind <david@davidnind.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #205402|0 |1 is obsolete| | -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=43490 --- Comment #5 from David Nind <david@davidnind.com> --- Created attachment 205426 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=205426&action=edit Bug 43490: Fix advanced editor widget marcWidgetPrefill This change fixes the marcWiedgetPrefill in the advanced editor so that it properly stops processing a line when it does a marcWidgetPrefill, so that the updated line gets actioned instead of the original line, which can have the wrong offsets in some situations (e.g. $2 empty gets prefilled to $2ddc which causes an issue for $cBK). Test plan: 0. Don't apply the patch yet 1. Import the attached "Problematic MARCXML record" 2. Enable the "EnableAdvancedCatalogingEditor" system preference 3. Edit the problematic record using the Advanced Editor 4. Note that the editor doesn't finish loading and you get a console error like "Uncaught Error: Inserting collapsed marker partially overlapping an existing one" 5. Apply the patch 6. Refresh the page with the advanced editor 7. Note that it now loads and the 942$2 has a widget that defaults to "Dewey Decimal Classification" and a 942$c widget that defaults to "Books" 8. Time to celebrate! Signed-off-by: David Nind <david@davidnind.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=43490 David Nind <david@davidnind.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |david@davidnind.com --- Comment #6 from David Nind <david@davidnind.com> --- Testing notes (using KTD): 1. After applying the patch you need to clear the browser cache to get rid of the console error and for the advanced editor to correctly load. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=43490 Owen Leonard <oleonard@myacpl.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Version|unspecified |Main -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=43490 Lisette Scheer <lisette@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |lisette@bywatersolutions.co | |m QA Contact|testopia@bugs.koha-communit |andrew@bywatersolutions.com |y.org | -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org