Bug 40711: Fix valuebuilder for UNIMARC 181c and 2

Test plan (UNIMARC ONLY):
1 - Make sure you have valuebuilder enabled for 181$c and 181$2 (see hereafter)
2 - Edit any record. Use valuebuilder to set 181$c to "cri - cartographic image", notice there is no change
3 - Use valuebuilder to set 181$c to "crm - cartographic moving image", notice it is set to "a"
4 - Open the valuebuilder for 181$2 and inspect the body ID. See it is cat_unimarc_field_182-2.
5 - Apply patch
6 - Repeat 2&3 and notice the codes are now cri respectively cri and crm
7 - Open the valuebuilder for 181$2 and inspect the body ID. See it is cat_unimarc_field_181-2.

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

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
(cherry picked from commit 4996ea8691)
Signed-off-by: Jacob O'Mara <Jacob.omara@openfifth.co.uk>
This commit is contained in:
Baptiste Wojtkowski 2025-08-27 11:40:40 +00:00 committed by Jacob O'Mara
parent cdacd29741
commit 2895e9ee7f
No known key found for this signature in database
2 changed files with 4 additions and 4 deletions

View File

@ -10,7 +10,7 @@
[% INCLUDE 'doc-head-close.inc' %]
</head>
<body id="cat_unimarc_field_182-2" class="cat value_builder">
<body id="cat_unimarc_field_181-2" class="cat value_builder">
<h3>UNIMARC field 181-2 builder</h3>

View File

@ -22,15 +22,15 @@
<td>
<select name="f1" id="f1">
[% IF ( f1 == "cri" ) %]
<option value=" " selected="selected">cri - cartographic image</option>
<option value="cri" selected="selected">cri - cartographic image</option>
[% ELSE %]
<option value=" ">cri - cartographic image</option>
<option value="cri">cri - cartographic image</option>
[% END %]
[% IF ( f1 == "crm" ) %]
<option value="crm" selected="selected">crm - cartographic moving image</option>
[% ELSE %]
<option value="a">crm - cartographic moving image</option>
<option value="crm">crm - cartographic moving image</option>
[% END %]
[% IF ( f1 == "crt" ) %]