Created
March 23, 2012 19:44
-
-
Save sshaw/2174243 to your computer and use it in GitHub Desktop.
Ember.js Chosen Multiple Select
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Tested with 1.0.0-pre.2, 0.9.7 or less does not work. | |
// Chosen modified to search on @results_data[n].text not .html | |
App.ChosenMultipleSelect = Em.Select.extend({ | |
multiple: true, | |
attributeBindings: [ 'multiple' ], | |
didInsertElement: function() { | |
this._super(); | |
this.$().chosen(); | |
}, | |
selectionChanged: function() { | |
this.$().trigger('liszt:updated'); | |
}.observes('selection') | |
}); | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment