public function getParentalIndex() { $parentalIndex = "#" . str_pad($this->getId(), 3, '0', STR_PAD_LEFT); $this->level = 1; if ($this->getParent() !== null && $this->getParent() != 0) { $p = MemberJobPeer::retrieveByPK($this->getParent()); $parentalIndex = str_pad($p->getParentalIndex(), 3, '0', STR_PAD_LEFT) . "_" . $parentalIndex; $this->level += $p->level; } $this->parentalIndex = $parentalIndex; return $parentalIndex; }
public function getMemberJob($con = null) { include_once 'lib/model/om/BaseMemberJobPeer.php'; if ($this->aMemberJob === null && $this->id !== null) { $this->aMemberJob = MemberJobPeer::retrieveByPK($this->id, $con); } return $this->aMemberJob; }
public function getMemberJobRelatedByParent($con = null) { include_once 'lib/model/om/BaseMemberJobPeer.php'; if ($this->aMemberJobRelatedByParent === null && $this->parent !== null) { $this->aMemberJobRelatedByParent = MemberJobPeer::retrieveByPK($this->parent, $con); } return $this->aMemberJobRelatedByParent; }