I have a model with this validator :

Code:



validators: {
UnitPrice: 'presence',
No: 'presence',
},

But it doesn't work when modelValidation: true and the value is empty, so I overrided it in the following way to have a correct behavior :

Code:



Ext.override(Ext.data.validator.Presence, {
validate: function (value) {
if (value == '') return false;
return this.callParent(arguments);
}
});