yiisoft / validator

Yii validator library
https://www.yiiframework.com/
BSD 3-Clause "New" or "Revised" License
110 stars 36 forks source link

In date rules use `format` property for format date in error message when don't set other format properties #709

Open vjik opened 1 month ago

vjik commented 1 month ago

For example:

new Date(
    format: 'php:d.m.Y',
    min: '19.11.2013',
    max: '31.12.2099',
    skipOnEmpty: true,
),

In this case I expect that in error message date will be formatted as php:d.m.Y.