[英]Formatting of the Dojo dijit/form/TimeTextBox dropdown
I have a TimeTextBox in Dojo - it currently looks like this: 我在Dojo中有一个TimeTextBox-当前看起来像这样:
However, I want it to look like this (with the hours emphasized - but with 10 minute increments instead of 15): 但是,我希望它看起来像这样(强调了小时数-但增加了10分钟而不是15分钟):
What's the simplest way to do this? 最简单的方法是什么? Currently, I have these props set: 目前,我已经设置了以下道具:
<input id="${ns}atdExamStartTime" type="text" name="examStartTime" data-dojo-type="dijit/form/TimeTextBox"
style="width:8em;" required="true"
data-dojo-props="promptMessage:'Enter the start time for the exam',
invalidMessage:'This is not a valid time',
rangeMessage:'Exams must be scheduled between 8am and 10pm',
constraints:{min:'T08:00',max:'T21:59',clickableIncrement:'T00:10:00',visibleIncrement:'T00:10:00'}" />
Thanks in advance! 提前致谢!
I know this answer is a bit late, but I hope it can help someone in some way. 我知道这个答案有点晚了,但是我希望它可以以某种方式帮助某人。 It looks like your code should work, to me at least. 看来,您的代码至少应该对我有用。 Here is a working JS Fiddle with 10 minute increments displayed like you want: 这是一个工作中的JS小提琴,有10分钟的增量显示,如您所愿:
dijit.form.TimeTextBox({
type:"text",
name:"timePicker",
constraints:{
formatLength:"short",
pickerMin:"T08:00:00",
pickerMax:"T22:00:00",
clickableIncrement:"T00:10:00"
}
});
Try it here: http://jsfiddle.net/skyWB/104/ 在这里尝试: http : //jsfiddle.net/skyWB/104/
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.