public function getDoctorWorkTimeList(Doctor $doctor, MedOptima_DateTime $date = null) { $condition = $this->__getConditionClass(); $condition->setDoctor($doctor); if ($date) { $condition->setWeekday($date->getWeekday()); } return $this->__getEntitySearch($condition)->getResults(); }
public function isWorkingAt(MedOptima_DateTime $date) { $this->_getJoin()->add('join', 'medicalDoctorWorkTime', 'medicalDoctors', 'idDoctor'); $this->_getWhere()->add('weekday', '=', $date->getWeekday()); }