Prepare script

This commit is contained in:
Michael RICOIS 2017-11-28 17:14:35 +01:00
parent 39d6b1659e
commit 81ed63f2fb

View File

@ -0,0 +1,43 @@
<?php
$_SERVER['HTTP_HOST'] = 'www.bebeboutik.com';
$_SERVER['SERVER_NAME'] = 'www.bebeboutik.com';
$_SERVER['REMOTE_ADDR'] = '127.0.0.1';
$_SERVER['HTTP_PORT'] = 443;
$_SERVER['HTTP_X_FORWARDED_PORT'] = 443;
$_SERVER['SERVER_PORT'] = 443;
include __DIR__ . '/../../../config/settings.inc.php';
include __DIR__ . '/../../../config/config.inc.php';
if(!Tools::isCli()){
exit();
}
$longopts = array(
'verbose',
'dry-run',
);
$shortopts = "";
$options = getopt($shortopts, $longopts);
// Liste des crédits fidélites (bons de réduction) valident qui expire dans 1 mois
$sql = "SELECT * FROM ps_discount d WHERE d.active=1";
// ps_loyalty , ps_discount
// ps_loyalty.id_discount != 0
// if (ps_order_discount.id_order) WHEN NO id_order
// ps_discount.date_from
// ps_discount.date_to
// ps_discount.active = 1
// Customer => informations
// Envoi mail
// Créer un template mail FR, ES