Bug 29895: Fix 'add multiple items' button on neworderempty
Button [Add multiple items] stops responding when it's pressed and some multiple items added to basket It has a "visibility: hidden" we are trying to remove setting "display: inline" This is pretty ugly and certainly does not clean the code, but it's too messy and this patch fixes the problem easily. Test plan: Add a new order Click "Add multiple items", enter "2", click "Add". Confirm that you can use the "Add multiple items" again. Signed-off-by: Samu Heiskanen <samu.heiskanen@hypernova.fi> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
This commit is contained in:
parent
857b937cf9
commit
0d995fa55a
1 changed files with 2 additions and 2 deletions
|
@ -180,10 +180,10 @@ function cloneItemBlock(index, unique_item_fields, callback) {
|
|||
var buttonPlus = "<fieldset class=\"action\">";
|
||||
buttonPlus += '<input type="button" class="addItemControl" name="buttonPlus" style="cursor:pointer; margin:0 1em;" onclick="addItem(this,\'' + unique_item_fields + '\')" value="' + ( __("Add item") )+ '" />';
|
||||
buttonPlus += '<input type="button" class="addItemControl cancel" name="buttonClear" style="cursor:pointer;" onclick="clearItemBlock(this)" value="' + __("Clear") + '" />';
|
||||
buttonPlus += '<input type="button" class="addItemControl" name="buttonPlusMulti" onclick="javascript:this.nextSibling.style.display=\'inline\'; return false;" style="cursor:pointer; margin:0 1em;" value="' + __("Add multiple items") + '" />';
|
||||
buttonPlus += '<input type="button" class="addItemControl" name="buttonPlusMulti" onclick="javascript:this.nextSibling.style.display=\'inline\'; this.nextSibling.style.visibility=\'visible\'; return false;" style="cursor:pointer; margin:0 1em;" value="' + __("Add multiple items") + '" />';
|
||||
buttonPlus += '<span id="add_multiple_copies" style="display:none">'
|
||||
+ '<input type="text" inputmode="numeric" pattern="[0-9]*" class="addItemControl" id="multiValue" name="multiValue" placeholder="' + __("Number of items to add") + '" />'
|
||||
+ '<input type="button" class="addItemControl" name=buttonAddMulti" style="cursor:pointer; margin:0 1em;" onclick="checkCount( this ,\'' + unique_item_fields + '\')" value="' + __("Add") + '" />'
|
||||
+ '<input type="button" class="addItemControl" name="buttonAddMulti" style="cursor:pointer; margin:0 1em;" onclick="checkCount( this ,\'' + unique_item_fields + '\')" value="' + __("Add") + '" />'
|
||||
+ '<div class="dialog message">' + __("NOTE: Fields listed in the 'UniqueItemsFields' system preference will not be copied") + '</div>'
|
||||
+ '</span>';
|
||||
buttonPlus += "</fieldset>";
|
||||
|
|
Loading…
Reference in a new issue