2
0
forked from Wavyzz/dolibarr

NEW Bookmarks are into a combo list.

This commit is contained in:
Laurent Destailleur
2017-04-04 11:56:19 +02:00
parent 761ece3125
commit 9df4bac202
9 changed files with 116 additions and 49 deletions

View File

@@ -401,7 +401,7 @@ function ajax_combobox($htmlname, $events=array(), $minLengthToAutocomplete=0, $
if ($forcefocus) $msg.= '.select2(\'focus\')';
$msg.= ';'."\n";
if (count($events))
if (count($events)) // If an array of js events to do were provided.
{
$msg.= '
jQuery("#'.$htmlname.'").change(function () {
@@ -414,6 +414,7 @@ function ajax_combobox($htmlname, $events=array(), $minLengthToAutocomplete=0, $
});
function runJsCodeForEvent'.$htmlname.'(obj) {
console.log("Run runJsCodeForEvent'.$htmlname.'");
var id = $("#'.$htmlname.'").val();
var method = obj.method;
var url = obj.url;