public function getEmployeeMutationsJoinDepartment($criteria = null, $con = null) { include_once 'lib/model/om/BaseEmployeeMutationPeer.php'; if ($criteria === null) { $criteria = new Criteria(); } elseif ($criteria instanceof Criteria) { $criteria = clone $criteria; } if ($this->collEmployeeMutations === null) { if ($this->isNew()) { $this->collEmployeeMutations = array(); } else { $criteria->add(EmployeeMutationPeer::EMPLOYEE_LEVEL_ID, $this->getId()); $this->collEmployeeMutations = EmployeeMutationPeer::doSelectJoinDepartment($criteria, $con); } } else { $criteria->add(EmployeeMutationPeer::EMPLOYEE_LEVEL_ID, $this->getId()); if (!isset($this->lastEmployeeMutationCriteria) || !$this->lastEmployeeMutationCriteria->equals($criteria)) { $this->collEmployeeMutations = EmployeeMutationPeer::doSelectJoinDepartment($criteria, $con); } } $this->lastEmployeeMutationCriteria = $criteria; return $this->collEmployeeMutations; }