I’ve added simple birthday date field validation rules into my rules() method:
public function rules()
{
$rules = [
// ...
['birthday', 'date', 'format' => 'php:Y-m-d'],
// ...
];
// ...
}
It is working correctly: only date in requested format is allowed.
But I also want to disable years in the future, years older than 90 from the past.
Is it possible to add such additional parameters to rules set for date field or I should write custom validator by myself?