コード例 #1
0
 public function actionSave()
 {
     $help = new CHelp();
     $help->setAttributes(CRequest::getArray($help::getClassName()));
     if ($help->validate()) {
         $help->save();
         if ($this->continueEdit()) {
             $this->redirect("?action=edit&id=" . $help->getId());
         } else {
             $this->redirect("?action=index");
         }
     }
     $this->addCSSInclude("_modules/_redactor/redactor.css");
     $this->addJSInclude("_modules/_redactor/redactor.min.js");
     $this->setData("help", $help);
     $this->renderView("_help/add.tpl");
 }