17 Dec 2011 3:14 AM #1
Unanswered: Multi select options in sencha 2
I have used selectfield for dropdown. but i need to select multiple options.
Can any one help to select multiple options in sencha 2?
17 Dec 2011 7:29 AM #2
- Join Date
- Mar 2007
- Gainesville, FL
- Vote Rating
Looks like the out of the box Select field doesn't support multi select. The problem having multi select on the Select field is if you use it on a tablet or desktop, it is the list which can support multi select but if you use it on a phone, it's a picker which isn't multi select so you can't rely on Select being multi select.
I created an extension that did this for Sencha Touch 1 that I gave the developer the option to choose between a list, dataview and picker. Since I gave the developer the choice, I could then allow multi select on the list and dataview. The problem with this is now the web app won't be true to it's native cousins as on a phone the picker should be used.Mitchell Simoens @SenchaMitch
Sencha Inc, Senior Software Engineer
Check out my GitHub, lots of nice things for Ext JS 4 and Sencha Touch 2
Think my support is good? Get more personalized support via a support subscription. https://www.sencha.com/store/
Need more help with your app? Hire Sencha Services email@example.com
Want to learn Sencha Touch 2? Check out Sencha Touch in Action that is in print!
When posting code, please use BBCode's CODE tags.
20 Jan 2012 1:00 PM #3
I am trying to use the muti-select extension you designed for Sencha Touch 1 with Sencha Touch 2 PR3 and have had some success getting it updated. My app is designed for a tablet, so I am interested in the "list" mode of your extension.
One issue: line 207 uses a deprecated property - fieldEl. When debugging, the console reports below from line 40862 of sencha-touch-all-debug.js:
"[DEPRECATE][Ext.form.ux.touch.MultiSelect#undefined] 'fieldEl' is deprecated, please use getInput() to get an instance of Ext.field.Field instead"
And then Afterwards:
"Uncaught TypeError: Object [object Object] has no method 'getInput'"
My question is: how would you recommend changing that line of code such that the correct property is set using Sencha Touch2 PR3's updated components?
Thanks again for providing this.