angular-multiselect
angular-multiselect copied to clipboard
Fixes for issues - #94 #95 #92 and made path to multiselect.tmpl.html relative
File changed - multiselect.js
Fix for issues -
- single select - button text is not mapped correctly to the string modal value #95
- single select - button text is not mapped correctly to the model value #94
- Show only one property but select complete object #92
- Made the path to multiselect.tmpl.html relative to multiselect.js in file multiselect.js. - Solution from -- http://stackoverflow.com/a/21103831/1298824
Changes made -
-
Added a new function - getItemLabel(items,model)
-
Calling the above function in function getHeaderText()
-
get the currentScriptPath // getting the path of the multiselect.js file var scripts = document.getElementsByTagName("script") var currentScriptPath = scripts[scripts.length-1].src;
-
Used the currentScriptPath as below - templateUrl: function (element, attr) { // multiselect.tmpl.html path relative to multiselect.js return attr.templateUrl || currentScriptPath.substring(0, currentScriptPath.lastIndexOf('/') + 1) + 'multiselect.tmpl.html'; },
Plnkr link after fixes - link3
Thanks! Can you update the readme, github pages with new changes?
Looks like last few pulls were into master branch. gh-pages branch is not in sync with the master. Its missing few updates.