Reputation: 1440
In dijit/form/DateTextBox
I can change the data-dojo-props="constraints: { datePattern: 'yyyy-MM-dd', min: '2000', max: '2018'}, invalidMessage: 'Choose date as yyyy-mm-dd'"
to set format, range, and change the message shown when the date is in wrong format. But when the date is just out of the range 2000 to 2018 I get a different message. How to customize that one? Dojo documentation doesn't help - it says something about min and max, but doesn't state what message is shown neither how to change that.
Upvotes: 0
Views: 401
Reputation: 725
You can user the rangeMessage
property:
data-dojo-props="constraints: { datePattern: 'yyyy-MM-dd', min: '2000', max: '2018'}, invalidMessage: 'Choose date as yyyy-mm-dd', rangeMessage: 'Choose a day between 2000 and 2018'"
This property is documented in the Dojo Toolkit API reference. Select dijit/form/DateTextBox and make sure that 'Inheriteds' is checked.
Upvotes: 2