public function get($sPropName) { if ($sPropName === "password" || $sPropName === "passwordconfirm") { # Special handling for password and passwordconfirm return ""; } try { # does the property exist on the model object ? $sRes = parent::get($sPropName); } catch (\Exception $e) { # no, it may belong to the oIdentityPrincipal model object $sRes = $this->oIdentityPrincipal->get($sPropName); } return $sRes; }
public function get($sPropName) { if ($sPropName === "todos") { # TRUE if components contains VTODO, FALSE otherwise if (($sComponents = $this->get("components")) !== "") { $aComponents = explode(",", $sComponents); } else { $aComponents = array(); } return in_array("VTODO", $aComponents); } if ($sPropName === "notes") { # TRUE if components contains VJOURNAL, FALSE otherwise if (($sComponents = $this->get("components")) !== "") { $aComponents = explode(",", $sComponents); } else { $aComponents = array(); } return in_array("VJOURNAL", $aComponents); } return parent::get($sPropName); }