Opened 10 years ago

Closed 10 years ago

Last modified 8 years ago

#9952 closed defect (fixed)

invalidMessage for dijit.form.DateTextBox doesn't popup onfocus of the DateTextBox control

Reported by: Jay Owned by: Douglas Hays
Priority: high Milestone: 1.4
Component: Dijit - Form Version: 1.3.2
Keywords: Cc:
Blocked By: Blocking:

Description

Not sure if this is a side-effect or was done by-design, but:

With both dijit.form.DateTextBox? and dijit.form.TimeTextBox?, the invalidMessage "popup" does not behave the same as it does for other widgets which subclass dijit.form.ValidationTextBox? (for e.g. NumberTextBox?).

Specifically, when a DateTextBox? control containing invalid data receives focus, it does not show its invalid message.

To see this: type an invalid date ("aaaa") into a DateTextBox?, click elsewhere so that the control looses focus, now click back into the DateTextBox? and note that the invalid message is not displayed. The only way to see the invalid message of the focussed control is to press some keys which will change the (invalid) value displayed by the DateTextBox?.

This is not the case for things like NumberTextBox?, where the invalid message is displayed as soon as the invalid NumberTextBox? control gets focus.

Attachments (1)

_DateTimeTextBox-onfocus.patch (354 bytes) - added by Jay 10 years ago.
patch to run the ValidationTextBox?._onFocus method from the overriden _DateTimeTextBox._onFocus

Download all attachments as: .zip

Change History (6)

Changed 10 years ago by Jay

patch to run the ValidationTextBox?._onFocus method from the overriden _DateTimeTextBox._onFocus

comment:1 Changed 10 years ago by Jay

Looks like a small modification to the overridden _DateTimeTextBox.js _onFocus function may resolve this. I've attached a patch.

comment:2 Changed 10 years ago by bill

Owner: set to Douglas Hays

Oh, just a one line change and at first glance it sure looks like a bug (an oversight), just forgetting the this.inherited() call.

comment:3 Changed 10 years ago by Douglas Hays

Milestone: tbd1.4
Status: newassigned

comment:4 Changed 10 years ago by Douglas Hays

Resolution: fixed
Status: assignedclosed

(In [20222]) Fixes #9952 !strict. Add missing this.inherited to _onFocus

comment:5 Changed 8 years ago by bill

Component: DijitDijit - Form
Note: See TracTickets for help on using tickets.