From 05767a213ee5d18ca5bb0ce4cdcc8fb71b935fe4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A9mi=20Gaillard?= Date: Tue, 4 Jun 2013 14:21:18 +0200 Subject: [PATCH] [*] Installer: you can now choose to send an email to the administrator after installation with php-cli --- install-dev/classes/datas.php | 7 ++++++- install-dev/controllers/console/process.php | 8 ++++---- 2 files changed, 10 insertions(+), 5 deletions(-) diff --git a/install-dev/classes/datas.php b/install-dev/classes/datas.php index 964d737cf..feba9c196 100644 --- a/install-dev/classes/datas.php +++ b/install-dev/classes/datas.php @@ -133,6 +133,11 @@ class Datas 'default' => 1, 'help' => 'get news from PrestaShop', ), + 'send_email' => array( + 'name' => 'send_email', + 'default' => 1, + 'help' => 'send an email to the administrator after installation', + ), ); protected $datas = array(); @@ -200,4 +205,4 @@ class Datas return count($errors) ? $errors : true; } -} +} \ No newline at end of file diff --git a/install-dev/controllers/console/process.php b/install-dev/controllers/console/process.php index 4b3923dda..4fc78079b 100644 --- a/install-dev/controllers/console/process.php +++ b/install-dev/controllers/console/process.php @@ -110,8 +110,9 @@ class InstallControllerConsoleProcess extends InstallControllerConsole $this->printErrors(); if (!$this->processInstallTheme()) $this->printErrors(); - if (!$this->processSendEmail()) - $this->printErrors(); + if ($this->datas->send_email) + if (!$this->processSendEmail()) + $this->printErrors(); if ($this->datas->newsletter) { @@ -287,5 +288,4 @@ class InstallControllerConsoleProcess extends InstallControllerConsole { return $this->model_install->installModulesAddons(); } -} - +} \ No newline at end of file