public function actionStep4() { error_reporting(E_ALL & ~E_NOTICE & ~E_STRICT); $conf_form = new InstallConfig(); $conf_form_long = new AdminConfig(); $conf_form->getAvailableStep(); if ($conf_form->available_step < 4) { $this->redirect($this->createUrl('install/step3')); } if (Yii::app()->request->isPostRequest && isset($_POST['schedule'])) { $conf_form->setSchedule(); $conf_form_long->deleteSync(); $conf_form_long->createSync(); } $conf_form->getAvailableStep(); $this->render('step4', array('conf_form' => $conf_form, 'conf_form_long' => $conf_form_long)); }
public function actionLongDbTask() { $conf_form = new AdminConfig(); if (!$conf_form->status) { $this->redirect($this->createUrl('superadmin/longdbsetup')); } // $conf_form->init_sync(); if (Yii::app()->request->isPostRequest and (isset($_POST['save_db_sync']) or isset($_POST['delete_db_sync']))) { $conf_form->attributes = $_POST['AdminConfig']; if ($conf_form->validate()) { $conf_form->saveDBSYNCConfig(); $conf_form->deleteSync(); if (isset($_POST['save_db_sync'])) { $conf_form->createSync(); } } } $this->render('longdbtask', array('conf_form' => $conf_form, 'const' => Yii::app()->params['CONST']['delete_periodicity'], 'periodicity' => Yii::app()->params['CONST']['periodicity'])); }