public function compareStartdateWithWeekday()
{
try {
$start_date = new DateTime($this->start_date);
} catch (Exception $e) {
$this->addError('start_date', 'Start date format error');
}
if ($this->weekday != $start_date->format('N')) {
$this->addError('start_date', 'Start date and weekday must be on the same day of the week');
}
}