Bug 8683: ensure clear button clears all item fields on order form
The clear js function parses input text, but input filled to a plugin does not contain the type attribute. Test plan: - fill the barcode field to the barcode plugin - go on the new order page - verify the barcode plugin works as before - verify the clear link clears the barcode field and all others fields. Signed-off-by: Owen Leonard <oleonard@myacpl.org> Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de> Works as expected, passes all tests and QA script. Template change only. Barcode and date acquired are now also cleared with the 'clear' link. But: it only works when you enter a barcode manually currently, because the AutoBarcode functionality is broken on master (bug 11273). Signed-off-by: Galen Charlton <gmc@esilibrary.com> (cherry picked from commitf3b28a5d8a) Signed-off-by: Fridolin SOMERS <fridolin.somers@biblibre.com> (cherry picked from commit842724659c) Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
This commit is contained in:
parent
e74d3780c9
commit
f3c8be69c9
|
|
@ -2776,14 +2776,14 @@ sub PrepareItemrecordDisplay {
|
|||
my $extended_param = plugin_parameters( $dbh, undef, $tagslib, $subfield_data{id}, undef );
|
||||
my ( $function_name, $javascript ) = plugin_javascript( $dbh, undef, $tagslib, $subfield_data{id}, undef );
|
||||
$subfield_data{random} = int(rand(1000000)); # why do we need 2 different randoms?
|
||||
$subfield_data{marc_value} = qq[<input tabindex="1" id="$subfield_data{id}" name="field_value" class="input_marceditor" size="67" maxlength="255"
|
||||
$subfield_data{marc_value} = qq[<input type="text" tabindex="1" id="$subfield_data{id}" name="field_value" class="input_marceditor" size="67" maxlength="255"
|
||||
onfocus="Focus$function_name($subfield_data{random}, '$subfield_data{id}');"
|
||||
onblur=" Blur$function_name($subfield_data{random}, '$subfield_data{id}');" />
|
||||
<a href="#" class="buttonDot" onclick="Clic$function_name('$subfield_data{id}'); return false;" title="Tag Editor">...</a>
|
||||
$javascript];
|
||||
} else {
|
||||
warn "Plugin Failed: $plugin";
|
||||
$subfield_data{marc_value} = qq(<input tabindex="1" id="$subfield_data{id}" name="field_value" class="input_marceditor" size="67" maxlength="255" />); # supply default input form
|
||||
$subfield_data{marc_value} = qq(<input type="text" tabindex="1" id="$subfield_data{id}" name="field_value" class="input_marceditor" size="67" maxlength="255" />); # supply default input form
|
||||
}
|
||||
}
|
||||
elsif ( $tag eq '' ) { # it's an hidden field
|
||||
|
|
|
|||
Loading…
Reference in New Issue