Ejemplo n.º 1
0
 public function canBeDeleted()
 {
     $criteria = new Criteria();
     $criteria->add(CourseSubjectDayPeer::CLASSROOM_ID, $this->getId());
     return CourseSubjectDayPeer::doCount($criteria) == 0;
 }
Ejemplo n.º 2
0
 public function isConfiguredToCourse($day_number)
 {
     $c = new Criteria();
     $c->add(CourseSubjectDayPeer::COURSE_SUBJECT_ID, $this->getId());
     $c->add(CourseSubjectDayPeer::DAY, $day_number);
     return CourseSubjectDayPeer::doCount($c) > 0;
 }