/** * @return bool */ public function saveObject() { if (!$this->checkInput()) { return false; } $this->object->setTitle($this->getInput(self::F_TITLE)); $this->object->setDescription($this->getInput(self::F_DESCRIPTION)); // $this->object->setStatus($this->getInput(self::F_STATUS)); $assigned_courses = $this->getInput(self::F_ASSIGNED_COURSES); $this->object->setAssignedCourses(explode(',', $assigned_courses[0])); $assigned_groups = $this->getInput(self::F_ASSIGNED_GROUPS); $this->object->setAssignedGroupes(explode(',', $assigned_groups[0])); $this->object->setGlobalRole($this->getInput(self::F_GLOBAL_ROLE)); $portfolio_template_id = $this->getInput(self::F_PORTFOLIO_TEMPLATE_ID); $this->object->setPortfolioTemplateId($portfolio_template_id > 0 ? $portfolio_template_id : NULL); $portf_assigned_to_groups = $this->getInput(self::F_PORTFOLIO_ASSIGNED_TO_GROUPS); $this->object->setPortfolioAssignedToGroups(explode(',', $portf_assigned_to_groups[0])); $this->object->setBlogName($this->getInput(self::F_BLOG_NAME)); $this->object->setPortfolioName($this->getInput(self::F_PORTFOLIO_NAME)); $assigned_orgus = $this->getInput(self::F_ASSIGNED_ORGUS); $this->object->setAssignedOrgus(explode(',', $assigned_orgus[0])); $assigned_studyprograms = $this->getInput(self::F_ASSIGNED_STUDYPROGRAMS); $this->object->setAssignedStudyprograms(explode(',', $assigned_studyprograms[0])); $this->object->setSkin($this->getInput(self::F_SKIN)); $this->object->setUsrStartingPoint($this->getInput(self::F_USR_START)); $this->object->setUsrStartingPointRefId($this->getInput(self::F_USR_START_REF_ID)); if ($this->object->getId() > 0) { $this->object->update(); } else { $this->object->create(); } return true; }