ext日期控件怎么在html里面写
1个回答
2014-11-12
展开全部
dateTimeField_s.js 代码
Ext.form.DateTimeField = Ext.extend(Ext.form.TriggerField, {
format : "m/d/Y H:i:s",
altFormats : "m/d/Y|m-d-y|m-d-Y|m/d|m-d|md|mdy|mdY|d|Y-m-d",
disabledDays : null,
disabledDaysText : "Disabled",
disabledDates : null,
disabledDatesText : "Disabled",
minValue : null,
maxValue : null,
minText : "The date in this field must be equal to or after {0}",
maxText : "The date in this field must be equal to or before {0}",
invalidText : "{0} is not a valid date - it must be in the format {1}",
triggerClass : 'x-form-date-trigger',
defaultAutoCreate : {tag: "input", type: "text", size: "10", autocomplete: "off"},
initComponent : function(){
Ext.form.DateTimeField.superclass.initComponent.call(this);
if(typeof this.minValue == "string"){
this.minValue = this.parseDate(this.minValue);
}
if(typeof this.maxValue == "string"){
this.maxValue = this.parseDate(this.maxValue);
}
this.ddMatch = null;
if(this.disabledDates){
var dd = this.disabledDates;
var re = "(?:";
for(var i = 0; i < dd.length; i++){
re += dd[i];
if(i != dd.length-1) re += "|";
}
this.ddMatch = new RegExp(re + ")");
}
},
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询