[Rt-commit] rt branch, 4.6/selectize-multiple-user-inputs, updated. rt-4.4.4-78-ga4c699754
? sunnavy
sunnavy at bestpractical.com
Wed May 8 16:09:05 EDT 2019
The branch, 4.6/selectize-multiple-user-inputs has been updated
via a4c6997549a65808a689418d0e794db168bab2d8 (commit)
from 689ad00e31a36b2033a74761c1e40e76c891496e (commit)
Summary of changes:
share/static/js/autocomplete.js | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
- Log -----------------------------------------------------------------
commit a4c6997549a65808a689418d0e794db168bab2d8
Author: sunnavy <sunnavy at bestpractical.com>
Date: Thu May 9 03:56:55 2019 +0800
Sync labels on bubbles drag/drop
As we show lables in bubbles, it's important to keep it consistent.
diff --git a/share/static/js/autocomplete.js b/share/static/js/autocomplete.js
index 9756842a3..680c7cc01 100644
--- a/share/static/js/autocomplete.js
+++ b/share/static/js/autocomplete.js
@@ -22,6 +22,7 @@ Selectize.define('rt_drag_drop', function(options) {
var self = input.selectize()[0].selectize;
var value = ui.item.attr('data-value');
self.createItem(value, false);
+ self.getItem(value).children('span').text(ui.item.children('span').text());
self.getItem(value).insertBefore(ui.item);
ui.item.remove();
self.setCaret(self.items.length);
@@ -68,7 +69,7 @@ window.RT.Autocomplete.bind = function(from) {
return '<div class="option">' + escape(data.label) + '</div>';
},
item: function(data, escape) {
- return '<div class="item">' + escape(data.label) + '</div>';
+ return '<div class="item">' + '<span>' + escape(data.label) + '</span></div>';
}
},
onItemRemove: function(value) {
-----------------------------------------------------------------------
More information about the rt-commit
mailing list