/** * Store form input in role object * @return * @param object $role */ protected function loadRoleProperties(ilObjRole $role) { $role->setTitle($this->form->getInput('title')); $role->setDescription($this->form->getInput('desc')); $role->setAllowRegister($this->form->getInput('reg')); $role->toggleAssignUsersStatus($this->form->getInput('la')); $role->setDiskQuota($this->form->getInput('disk_quota') * pow(ilFormat::_getSizeMagnitude(), 2)); $role->setPersonalWorkspaceDiskQuota($this->form->getInput('wsp_disk_quota') * pow(ilFormat::_getSizeMagnitude(), 2)); return true; }
/** * Store form input in role object * @return * @param object $role */ protected function loadRoleProperties(ilObjRole $role) { //Don't set if fields are disabled to prevent html manipulation. if (!$this->form->getItemByPostVar('title')->getDisabled()) { $role->setTitle($this->form->getInput('title')); } if (!$this->form->getItemByPostVar('desc')->getDisabled()) { $role->setDescription($this->form->getInput('desc')); } $role->setAllowRegister($this->form->getInput('reg')); $role->toggleAssignUsersStatus($this->form->getInput('la')); $role->setDiskQuota($this->form->getInput('disk_quota') * pow(ilFormat::_getSizeMagnitude(), 2)); $role->setPersonalWorkspaceDiskQuota($this->form->getInput('wsp_disk_quota') * pow(ilFormat::_getSizeMagnitude(), 2)); return true; }