From 6efb6830a24555809be7b1cff1faf156f7cb67a2 Mon Sep 17 00:00:00 2001 From: Hector Castro Date: Thu, 20 Oct 2016 08:57:46 -0600 Subject: [PATCH] Bug 17477: Duplicating a subfield yields an empty subfield tag MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit The problem only when clone a textareas in 5XX Steps to reproduce error: - On the cataloging screen (basic screen), create a new record - Go to the 5xx fields - Put something on the 521$a subfield or other textareas (e.g. 520$u or 583$x) - Clone the subfield => FAIL: The subfield correctly doesn't include the original data, BUT it doesn't have the subtield tag either. - Apply patch - Clean cache browser and reload page - Repeat steps above - Verify that works as expected Signed-off-by: Tomas Cohen Arazi Signed-off-by: Kyle M Hall (cherry picked from commit fbe75e66ccb93a6a4d973e3066ca1ebad169a5b6) Signed-off-by: Frédéric Demians (cherry picked from commit 90e9ab941eb47b0be4f859c45d394575324b5fc7) Signed-off-by: Julian Maurice --- koha-tmpl/intranet-tmpl/prog/en/js/cataloging.js | 1 + 1 file changed, 1 insertion(+) diff --git a/koha-tmpl/intranet-tmpl/prog/en/js/cataloging.js b/koha-tmpl/intranet-tmpl/prog/en/js/cataloging.js index 5f645c0965..edd48da57f 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/js/cataloging.js +++ b/koha-tmpl/intranet-tmpl/prog/en/js/cataloging.js @@ -288,6 +288,7 @@ function CloneSubfield(index, advancedMARCEditor){ id_input = textareas[i].getAttribute('id')+new_key; textareas[i].setAttribute('id',textareas[i].getAttribute('id')+new_key); textareas[i].setAttribute('name',textareas[i].getAttribute('name')+new_key); + linkid = id_input; } // Handle click event on buttonDot for plugin -- 2.39.5