Login Register

TimeTextBox

Do DateTextBox, TimeTextBox support Date and Time selection?

Hi guys,

I've been trying to find out whether dojo supports a Date+Time selection widget. The documentation is a little confusing. The book of dojo mentions that the "selector" attribute for DateTextBox, TimeTextBox has a default of 'both'. (http://dojotoolkit.org/book/dojo-book-0-9/part-2-dijit/form-validation-s...)

However, this ticket ( http://trac.dojotoolkit.org/ticket/1872 ) suggests that a Date + Time widget is being considered for the future.

dijit.TimeTextBox not working at minutes/seconds scale

I'm trying to use the dijit.TimeTextBox with the timePattern set to 'mm:ss', but it is just showing a bunch of 00:00s in the drop down (and then If I hover over the blank areas it shows (00:45, 00:30). Does it not work at this "resolution" or am I doing something wrong?

How to use min and max in TimeTextBox?

I want to know how i can use min and max in the constraints of an TimeTextBox?

Following does not work:

<input type="text" name="time" value="T09:00:00"
                dojoType="dijit.form.TimeTextBox"
                constraints="{ min:'T09:00:00', max:'T10:00:00' }"
                required="true"
                />

TimeTextBox in Grid

I've gotten the TimeTextBox to work, sort of, in a grid by including a dojo.declare in the script section of my JSP:

dojo.declare(
	"dojox.grid.editors.TimeTextBox", dijit.form.editors.Dijit,
	{	

..

But, I can't get the result to format properly. I keep getting a full date/time like: Sat Jan 01 1972 14:00:00 GMT-0500 (Eastern Standard Time) instead of just "HH:MM A".

I've tried

dojo.declare("dojox.grid.editors.TimeTextBox", dijit.form.editors.Dijit,{
	editorClass: "dijit.form.TimeTextBox",

HELLO? IS THERE ANYONE THERE???? dojox.grid.editors.TimeTextBox

Has anyone gotten the TimeTextBox to work in a grid? Any assistance would be greatly appreciated.

My JSON data is in the format of 9:53 A, 10:14 P, etc ...

this is the TimeTextBox snippet from my gridLayout:

{name: 'Time In', width: '15%', field: 'timeIn', editor: dojox.grid.editors.TimeTextBox , constraint: {formatLength: 'short'}},

I've also tried:

{name: 'Time In', width: '15%', field: 'timeIn', editor: dojox.grid.editors.TimeTextBox , constraint:
{timePattern:'h:mm:ss a'}},

setting DateTextBox and TimeTextBox size

Hi everyone!

First of all, my greetings for this incredible toolkit, I just can imagine the hard work it has required...
Going straight to the point, I would like to change (exactly, to decrease) the size of a DateTextBox and a TimeTextBox (in other words, I need to set the width of the field to a shorter value).
On the Dojo book, I noticed the size attribute. I tried to set the size this way:
var startDate = new dijit.form.DateTextBox({ id: 'startDate',
constraints: {datePattern:'dd/MM/yyyy'},
required: 'true' },dojo.byId('startDatePickerDiv')

timetextbox and datetextbox prefill data not available in ISO format

I'm trying to get the timetextbox and datetextbox up and running on an existing platform, and I'm stuck. My system already accepts mm-dd-yyyy formating (and I worked that out with serialize:) but it also pre-fills with the same format. The problem is dojo will only accept yyyy-mm-dd as a valid format:

However, you must provide numbers and dates from the server in JavaScript format. This goes for the value property and the min and max constraint values. You may do the conversion at the server or through the dojo.getXhr callback.

TimeTextBox onChange firing twice

I've set an onChange function to a TimeTextBox that is firing twice; once when the value is selected from the drop down and again when the focus is moved off the widget. Is there a way to avoid the onChange happening twice or somehow cancel the second event?

modified test_TimeTextBox.html :

Syndicate content