#3164 closed defect (fixed)
dijit.form.Textbox contains an error preventing entering 0 values.
Reported by: | Eugene Lazutkin | Owned by: | Douglas Hays |
---|---|---|---|
Priority: | high | Milestone: | 0.9beta |
Component: | Dijit - Form | Version: | 0.9 |
Keywords: | Cc: | ||
Blocked By: | Blocking: |
Description
dijit.form.Textbox.setValue(value)
defined like that (in lines 52-55):
setValue: function(value){ this._setTextValue(!value ? "" : this.format(value, this.constraints)); dijit.form.Textbox.superclass.setValue.call(this,value); },
It means that if value
is evaluated to false
it will be replaced by an empty string. This is the case for dijit.form.NumberTextbox
, and, by proxy, for dijit.form.CurrencyTextbox
. If somebody tries to enter totally legal value of 0, it will be replaced by the empty string, which is less than desirable in general cases. This problem can be reproduced in the test page: try to enter legal 0 values as Age, Elevation, or Annual Income.
I am assigning this ticket to Bill, so he can reassign it later to a proper contributor.
Change History (3)
comment:1 Changed 14 years ago by
Owner: | changed from bill to Douglas Hays |
---|
comment:2 Changed 14 years ago by
Resolution: | → fixed |
---|---|
Status: | new → closed |
comment:3 Changed 10 years ago by
Component: | Dijit → Dijit - Form |
---|
Note: See
TracTickets for help on using
tickets.
Giving to Doug.