I am using extjs datefield
Ext.create('Ext.form.Panel', {
renderTo: Ext.getBody(),
width: 300,
items: [{
xtype: 'datefield',
fieldLabel: 'From',
maxValue: new Date()
}, {
xtype: 'datefield',
fieldLabel: 'To',
}]
});
when using this code in extjs 4 it works perfectly to disable all dates after today's date , It done by using maxValue= now Date()
.In extjs 5 the user can't select any day after today's date but it is not disable.
How can I disable these dates ??
Thanks in advance
Not sure you can... the invalid days have been given the right classes, and have all the correct setup. But the HTML is different.
In Ext4, the template for rendering a date cell is
But in Ext5, the template is
The other problem is that the SASS code for the styles still assumes that the cell is a
A
tag, not aDIV
In short, this appears to be a bug in ExtJS 5 - the Javascript widget has been converted, but the CSS isn't. I suggest raising the bug with them.