/** * @see Form::save() */ public function save() { AbstractForm::save(); // update item $this->helpItem->update($this->topic, $this->text, $this->parentItem, $this->refererPattern, $this->showOrder, $this->isDisabled, $this->languageID); HelpItemEditor::clearCache(); $this->saved(); // show success message WCF::getTPL()->assign('success', true); }
/** * @see Action::execute() */ public function execute() { parent::execute(); // check permissions WCF::getUser()->checkPermission('admin.help.canEditHelpItem'); // update $this->helpItem->enable($this->enable); // delete cache HelpItemEditor::clearCache(); $this->executed(); // forward to list page header('Location: index.php?page=HelpItemList&packageID=' . PACKAGE_ID . SID_ARG_2ND_NOT_ENCODED); exit; }
/** * @see Action::execute() */ public function execute() { parent::execute(); // check permissions WCF::getUser()->checkPermission('admin.help.canEditHelpItem'); // update postions foreach ($this->positions as $helpItemID => $data) { foreach ($data as $parentHelpItemID => $position) { $parentHelpItem = ''; if ($parentHelpItemID != 0) { $parentHelpObject = new HelpItem($parentHelpItemID); $parentHelpItem = $parentHelpObject->helpItem; } HelpItemEditor::updateShowOrder(intval($helpItemID), $parentHelpItem, $position); } } // delete cache HelpItemEditor::clearCache(); $this->executed(); // forward to list page header('Location: index.php?page=HelpItemList&successfullSorting=1&packageID=' . PACKAGE_ID . SID_ARG_2ND_NOT_ENCODED); exit; }
/** * @see Form::save() */ public function save() { parent::save(); // save $this->helpItem = HelpItemEditor::create($this->topic, $this->text, $this->parentItem, $this->refererPattern, $this->showOrder, $this->isDisabled, WCF::getLanguage()->getLanguageID()); HelpItemEditor::clearCache(); $this->saved(); // reset values $this->topic = $this->text = $this->parentItem = $this->refererPattern = ''; $this->languageID = $this->showOrder = $this->isDisabled = 0; // show success message WCF::getTPL()->assign('success', true); }