Bug 17477: Duplicating a subfield yields an empty subfield tag

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 <tomascohen@theke.io>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
This commit is contained in:
Hector Castro 2016-10-20 08:57:46 -06:00 committed by Kyle M Hall
parent 31cb200e0d
commit fbe75e66cc

View file

@ -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