|
|
@ -117,7 +117,7 @@ |
|
|
|
$.fn.autocomplete.defaults = { |
|
|
|
$.fn.autocomplete.defaults = { |
|
|
|
multiple: false, |
|
|
|
multiple: false, |
|
|
|
data: {}, |
|
|
|
data: {}, |
|
|
|
allowedAttributes: ["title", "placeholder", "id", "name"], |
|
|
|
allowedAttributes: ["title", "placeholder", "id", "name", "multiple"], |
|
|
|
minimumInputLength: 0, |
|
|
|
minimumInputLength: 0, |
|
|
|
ajax: { |
|
|
|
ajax: { |
|
|
|
null_element: null, |
|
|
|
null_element: null, |
|
|
@ -173,8 +173,8 @@ |
|
|
|
var data, |
|
|
|
var data, |
|
|
|
multiple = $(element).attr("multiple"); |
|
|
|
multiple = $(element).attr("multiple"); |
|
|
|
if (multiple !== null && multiple !== undefined && multiple) { |
|
|
|
if (multiple !== null && multiple !== undefined && multiple) { |
|
|
|
data = [] |
|
|
|
data = []; |
|
|
|
}; |
|
|
|
} |
|
|
|
if (!($(element).attr("data-selected") === "" || $(element).attr("data-selected") === null || $(element).attr("data-selected") === undefined)) { |
|
|
|
if (!($(element).attr("data-selected") === "" || $(element).attr("data-selected") === null || $(element).attr("data-selected") === undefined)) { |
|
|
|
JSON.parse($(element).attr('data-selected')).each(function (elem) { |
|
|
|
JSON.parse($(element).attr('data-selected')).each(function (elem) { |
|
|
|
if (multiple) { |
|
|
|
if (multiple) { |
|
|
|