/** * PROCESS : populateDatabase * Populate database with default data */ public function processPopulateDatabase() { $this->initializeContext(); $this->model_install->xml_loader_ids = $this->datas->xml_loader_ids; $result = $this->model_install->populateDatabase(); $this->datas->xml_loader_ids = $this->model_install->xml_loader_ids; return $result; }
/** * PROCESS : populateDatabase * Populate database with default data */ public function processPopulateDatabase() { $this->initializeContext(); $this->model_install->xml_loader_ids = $this->session->xml_loader_ids; $result = $this->model_install->populateDatabase(Tools::getValue('entity')); if (!$result || $this->model_install->getErrors()) { $this->ajaxJsonAnswer(false, $this->model_install->getErrors()); } $this->session->xml_loader_ids = $this->model_install->xml_loader_ids; $this->session->process_validated = array_merge($this->session->process_validated, array('populateDatabase' => true)); $this->ajaxJsonAnswer(true); }