public function actionSave()
 {
     $student = new CStudent();
     $student->setAttributes(CRequest::getArray(CStudent::getClassName()));
     if ($student->validate()) {
         $student->save();
         if ($this->continueEdit()) {
             $this->redirect("?action=edit&id=" . $student->getId());
         } else {
             $this->redirect("?action=index");
         }
         return true;
     }
     $this->addJSInclude("_core/jquery-ui-1.8.20.custom.min.js");
     $this->addCSSInclude("_core/jUI/jquery-ui-1.8.2.custom.css");
     $groups = array();
     foreach (CActiveRecordProvider::getAllFromTable(TABLE_STUDENT_GROUPS, "name asc")->getItems() as $item) {
         $group = new CStudentGroup($item);
         $groups[$group->getId()] = $group->getName();
     }
     $forms = array(1 => "Бюджет", 2 => "Контракт");
     $this->setData("forms", $forms);
     $this->setData("groups", $groups);
     $this->setData("student", $student);
     $this->renderView("_students/edit.tpl");
 }