[Koha-bugs] [Bug 33335] MARC overlay rules broken because of "categorycode.categorycode " which contains "-"

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Fri May 12 10:38:52 CEST 2023


https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33335

Marcel de Rooy <m.de.rooy at rijksmuseum.nl> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
 Attachment #149253|0                           |1
        is obsolete|                            |

--- Comment #12 from Marcel de Rooy <m.de.rooy at rijksmuseum.nl> ---
Created attachment 151119
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=151119&action=edit
Bug 33335: Fix JavaScript error on the MARC overlay rules page

The "MARC overlay rules" page doesn't display or work correctly
if a patron category code contains a "-".

This happens because of the JavaScript function in
"marc-overlay-rules.tt" line 469. This causes an error
"Uncaught SyntaxError: missing : after property id".

Test plan:
1. Go to Administration > Patron categories.
2. Make sure you don't have a patron category code that contains
   a "-".
3. Go to Administration > Record overlay rules.
4. The table should display correctly, and you can add, edit
   and delete rules.
5. Return to Patron categories.
6. Add a new patron category with a "-" in the patron category code.
7. Return to Record overlay rules page:
   => The page doesn't display and load correctly (see the attached
      image) - the normal DataTables header and footer aren't
      displayed, and you can't add, edit or delete overlay rules.
  => If you turn on web developer tools, an error is displayed in the
     console: "Uncaught SyntaxError: missing : after property id".
8. Apply the patch.
9. Repeat the step 7, the Record overlay rules page should now
   display correctly and you should be able to add, edit and
   delete rules.
10. Sign off.

Signed-off-by: David Nind <david at davidnind.com>

Signed-off-by: Marcel de Rooy <m.de.rooy at rijksmuseum.nl>

-- 
You are receiving this mail because:
You are watching all bug changes.


More information about the Koha-bugs mailing list