Merge branch 'fix_preprod_erp' into dev
This commit is contained in:
commit
9426808c2e
@ -73,6 +73,14 @@ foreach ($ids_customer as $id_customer) {
|
||||
continue;
|
||||
}
|
||||
}
|
||||
|
||||
if (defined('ERP_PREPROD') && ERP_PREPROD) {
|
||||
if (preg_match('/@roykin.fr$/', $email)!==1 ||
|
||||
preg_match('/@antadis.com$/', $email)!==1) {
|
||||
$email = 'roykin+'.md5($email).'@antadis.com';
|
||||
}
|
||||
}
|
||||
|
||||
// ppp($id_customer.' loop');
|
||||
// var_dump(ErpTools::alreadyExists($record['id']));
|
||||
// var_dump(Customer::getCustomersByEmail($email));
|
||||
|
@ -71,6 +71,14 @@ foreach ($ids_customer_update as $id_customer) {
|
||||
}
|
||||
}
|
||||
|
||||
if (defined('ERP_PREPROD') && ERP_PREPROD) {
|
||||
if (preg_match('/@roykin.fr$/', $email)!==1 ||
|
||||
preg_match('/@antadis.com$/', $email)!==1) {
|
||||
$email = 'roykin+'.md5($email).'@antadis.com';
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// 12611 - get rid of unwanted characters in phone number (eg "01 02 03 04 05 (PIERRE)" found in ERP)
|
||||
if (isset($record['phone']) && !empty($record['phone'])) {
|
||||
$record['phone'] = preg_replace('/[^\+0-9\. \(\)\-]+/', '', $record['phone']);
|
||||
|
Loading…
Reference in New Issue
Block a user