Skip to content
Snippets Groups Projects
Commit bbab5e5b authored by aspangaro's avatar aspangaro
Browse files

Merge remote-tracking branch 'Upstream/develop' into develop-hrm

parents 54091a06 e673b188
No related branches found
No related tags found
No related merge requests found
......@@ -52,16 +52,13 @@ function ajax_autocompleter($selected, $htmlname, $url, $urloption='', $minLengt
// Remove product id before select another product
// use keyup instead change to avoid loosing the product id
$("input#search_'.$htmlname.'").keydown(function() {
//console.log(\'purge_id_after_keydown\');
$("#'.$htmlname.'").val("");
});
$("input#search_'.$htmlname.'").change(function() {
//console.log(\'change\');
$("#'.$htmlname.'").trigger("change");
});
// Check when keyup
$("input#search_'.$htmlname.'").keyup(function() {
//console.log(\'keyup\');
if ($(this).val().length == 0)
{
$("#search_'.$htmlname.'").val("");
......@@ -127,7 +124,6 @@ function ajax_autocompleter($selected, $htmlname, $url, $urloption='', $minLengt
dataType: "json",
minLength: '.$minLength.',
select: function( event, ui ) { // Function ran when new value is selected into javascript combo
//console.log(\'set value of id with \'+ui.item.id);
$("#'.$htmlname.'").val(ui.item.id).trigger("change"); // Select new value
// Disable an element
if (options.option_disabled) {
......@@ -171,8 +167,6 @@ function ajax_autocompleter($selected, $htmlname, $url, $urloption='', $minLengt
}
});
}
console.log("ajax_autocompleter new value selected, we trigger change");
$("#search_'.$htmlname.'").trigger("change"); // To tell that input text field was modified
}
,delay: 500
}).data("ui-autocomplete")._renderItem = function( ul, item ) {
......
......@@ -523,7 +523,6 @@ jQuery(document).ready(function() {
/* When changing predefined product, we reload list of supplier prices */
$("#idprod, #idprodfournprice").change(function()
{
console.log("change #idprod, #idprodfournprice, conf->global->MARGIN_TYPE=<?php echo $conf->global->MARGIN_TYPE ?>");
setforpredef();
jQuery('#trlinefordates').show();
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment