Hybrid View
-
24 Feb 2011 10:05 AM #1
Ext.form.FormPanel.getValues() can't handle array inputfield
Ext.form.FormPanel.getValues() can't handle array inputfield
Sencha Touch version tested:
- 1.0.1a ____
- only default sencha-touch.css
Platform tested against:
- iOS 4
- Chrome 9
Description:
- When you have a inputfield that is an array like: fieldname[key][optional.][optional.], Sencha Touch will try to perform a isChecked function, because it expects an checkbox.
Test Case:
Steps to reproduce the problem:Code:var myPanel = new Ext.form.FormPanel({ items: [{ xtype: 'textfield', name: 'mytextfield[0][]' }, { xtype: 'textfield', name: 'mytextfield[0][]' }] });
- Create a formpanel object
- Add a textfield to this formpanel with an array-like name
- Request the formvalues with formPanel.getValues();
- See it go in flames
The result that was expected:
- It should give me back an array of textfields or maybe group it inside the textfield
The result that occurs instead:
- Uncaught TypeError: Object [object Object] has no method 'isChecked'
Possible fix:
- temporary fix for current applications is to extend the formpanel class in which you override the getValues() function and check whether the field Object has an function 'isChecked'
- permanent fix: rewrite the getValues to allow array-like textfields
-
16 Oct 2011 6:17 AM #2
Same here... but I dont't gen info from an Array.... Looking for a solution...
Thank you for reporting this bug. We will make it our priority to review this report.
Similar Threads
-
How do I find out when a FormPanel's form is accessible with getForm().getValues()?
By KallDrexx in forum Ext 3.x: Help & DiscussionReplies: 2Last Post: 10 Dec 2010, 8:15 AM -
How do I find out when a FormPanel's form is accessible with getForm().getValues()?
By KallDrexx in forum Ext 3.x: Help & DiscussionReplies: 1Last Post: 10 Dec 2010, 7:52 AM -
[3.1.1] multiple RadioGroups with same name - getValues not returning array
By danellison in forum Ext 3.x: Help & DiscussionReplies: 0Last Post: 18 May 2010, 8:12 AM -
editorgridpanel in formpanel need to post all rows as array within the form
By yekurt in forum Ext 2.x: Help & DiscussionReplies: 5Last Post: 24 Nov 2008, 7:25 PM -
[2.1][CLOSED] BasicForm.getValues() result array contain value of DateField as String
By danykey in forum Ext 2.x: BugsReplies: 1Last Post: 4 Jun 2008, 12:26 PM


Reply With Quote