/** * @see Form::save() */ public function save() { ACPForm::save(); // save $this->avatarCategory->update($this->title, $this->showOrder, $this->groupID, $this->neededPoints); $this->saved(); // show success message WCF::getTPL()->assign('success', true); }
/** * @see Action::execute() */ public function execute() { parent::execute(); // check permission WCF::getUser()->checkPermission('admin.avatar.canDeleteAvatarCategory'); // delete category $this->avatarCategory->delete(); $this->executed(); // forward to list page HeaderUtil::redirect('index.php?page=AvatarCategoryList&deletedAvatarCategoryID=' . $this->avatarCategoryID . '&packageID=' . PACKAGE_ID . SID_ARG_2ND_NOT_ENCODED); exit; }
/** * @see Form::save() */ public function save() { parent::save(); // save AvatarCategoryEditor::create($this->title, $this->showOrder, $this->groupID, $this->neededPoints); $this->saved(); // reset values $this->title = ''; $this->showOrder = $this->neededPoints = $this->groupID = 0; // show success message WCF::getTPL()->assign('success', true); }