getControlState('user'); } public function setUserToDisplay($user) { $this->setControlState('user', $user); } public function onPreRender($param) { parent::onPreRender($param); $this->Categories->setDataSource( $this->_getUserSelection($this->UserToDisplay) ); $this->Categories->dataBind(); } public function categoryDataBind($sender, $param) { $param->Item->Calendars->setDataSource($param->Item->Data->Calendars); $param->Item->Calendars->dataBind(); } public function removeFromSelection($sender, $param) { if (!$this->UserToDisplay->IsGuest) { } } private function _getUserSelection(DbUser $user) { return CalendarFacade::getInstance()->getPreferenceList($user); } } ?>