pattern matching improved
This commit is contained in:
parent
204695172f
commit
b7efc66cba
28 changed files with 6 additions and 4 deletions
|
|
@ -360,8 +360,9 @@ class timetable {
|
|||
$mylesson['subject'] = $substitution->subjectb;
|
||||
|
||||
if ($substitution->subjectb &&
|
||||
(($this->type == 'teacher' && $this->name == $substitution->teacherb) ||
|
||||
($this->type == 'class' && $this->name == $substitution->classb) ||
|
||||
(($this->type == 'teacher' && $this->name == $substitution->teacherb) ||
|
||||
// ($this->type == 'class' && $this->name == $substitution->classb) ||
|
||||
($this->type == 'class' && strpos($substitution->classb, $this->name)) ||
|
||||
($this->type == 'room' && $this->name == $substitution->roomb))
|
||||
) {
|
||||
|
||||
|
|
@ -376,8 +377,9 @@ class timetable {
|
|||
}
|
||||
}
|
||||
//if ($lesson->week[$this->week-1] != '0') $days[$day]['lessons'][] = $mylesson;
|
||||
} elseif (($this->type == 'teacher' && $this->name == $substitution->teachera) ||
|
||||
($this->type == 'class' && $this->name == $substitution->classa) ||
|
||||
} elseif (($this->type == 'teacher' && $this->name == $substitution->teachera) ||
|
||||
// ($this->type == 'class' && $this->name == $substitution->classa) ||
|
||||
($this->type == 'class' && strpos($substitution->classa, $this->name)) ||
|
||||
($this->type == 'room' && $this->name == $substitution->rooma)) {
|
||||
$mylesson['class'] = $substitution->classa;
|
||||
$mylesson['teacher'] = $substitution->teachera;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue