Hybrid View
-
26 Jul 2007 10:15 AM #1
[Closed]Grid returning empty string for a cell with value 0
[Closed]Grid returning empty string for a cell with value 0
I have a grid with a NumberField editor for one of the columns. When I enter 0 in the cell it renders correctly but the datasource contains an empty string (""). I am using Ext1.1 rc1 then I switched back to the old version Ext1.01a and it works just fine. Is this a known bug in rc1? Is there a work around. I tried searching the forum but turned up nothing. Can some body throw some light on this one.
Ok. Found out another thread saying that its a bug http://extjs.com/forum/showthread.ph...ht=numberfieldLast edited by surveyganga; 26 Jul 2007 at 10:26 AM. Reason: Reason
-
26 Jul 2007 10:28 AM #2
Confirmed - I see this with the EditGrid example price column in 1.1RC1. Moving to bugs.
Tim Ryan
Read BEFORE posting a question / BEFORE posting a Bug
Use Google to Search - API / Forum
API Doc (4.x | 3.x | 2.x | 1.x) / FAQ / 1.x->2.x Migration Guide / 2.x->3.x Migration Guide
-
27 Jul 2007 9:08 AM #3
Sencha Docs / Ext 3.x - ( Docs | Examples )
Learning Center / Saki's Examples (for 2.x) / HOWTO - ( Report Bugs | Post Proper Code )
-
18 Sep 2007 8:18 AM #4
Data store zero value matches empty string
Data store zero value matches empty string
I'm using prototype 1.5.1. But I also tested it with ext.base adapter.
The value for Store.getModifiedRecords()[0].data["ID"] is zero. However it matches the empty string ("" or ''). This was reportedly fixed for 1.1.1 as per the release notes.
-
18 Sep 2007 10:05 AM #5
pls post a complete test case (html file and all).
Sencha Docs / Ext 3.x - ( Docs | Examples )
Learning Center / Saki's Examples (for 2.x) / HOWTO - ( Report Bugs | Post Proper Code )
-
20 Sep 2007 6:51 AM #6
Here an extraction from the Ext.debug.js from the Ext.form.Field object
The line of code...Code:getValue : function(){ return this.fixPrecision(this.parseValue(Ext.form.NumberField.superclass.getValue.call(this))); }, parseValue : function(value){ return parseFloat(String(value).replace(this.decimalSeparator, ".")) || ''; },
..of the "parseValue" function force to return an empty value from the method call "Ext.form.Field.getValue()"Code:return parseFloat(String(value).replace(this.decimalSeparator, ".")) || '';


