2017-12-16 13:32:58 -07:00
|
|
|
/* This Source Code Form is subject to the terms of the Mozilla Public
|
|
|
|
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
|
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
|
|
|
|
2017-05-17 23:09:51 -06:00
|
|
|
$("#assignedto").easyAutocomplete({
|
|
|
|
url: "action.php",
|
|
|
|
ajaxSettings: {
|
|
|
|
dataType: "json",
|
|
|
|
method: "GET",
|
|
|
|
data: {
|
|
|
|
action: "autocomplete_user"
|
|
|
|
}
|
|
|
|
},
|
|
|
|
preparePostData: function (data) {
|
|
|
|
data.q = $("#assignedto").val();
|
|
|
|
return data;
|
|
|
|
},
|
|
|
|
getValue: function (element) {
|
|
|
|
return element.username;
|
|
|
|
},
|
|
|
|
template: {
|
|
|
|
type: "custom",
|
|
|
|
method: function (value, item) {
|
|
|
|
return item.name + " <i class=\"small\">" + item.username + "</i>";
|
|
|
|
}
|
|
|
|
}
|
|
|
|
});
|
|
|
|
|
2017-12-26 17:53:04 -07:00
|
|
|
$('#name').on('input propertychange paste', function () {
|
2017-05-17 23:09:51 -06:00
|
|
|
$('#name_title').text($('#name').val());
|
2018-10-05 00:28:38 -06:00
|
|
|
});
|
|
|
|
|