add ILSA update debug flag to prevent mailing

This commit is contained in:
merelendor 2024-06-11 16:24:07 +03:00
parent 97b7e660cf
commit daea509f1e

View File

@ -2039,7 +2039,10 @@ while($sitemap_all_models_search_ob = $sitemap_all_models_search_res->GetNextEle
$model = $sitemap_all_models_search_ob->GetFields();
$model['PROPERTIES'] = $sitemap_all_models_search_ob->GetProperties();
if($model['PROPERTIES']['REGIONS']['VALUE'] == "Да")
{
array_push($sitemap_brands[$model['PROPERTY_BRAND_UID_VALUE']]['MODELS'], $model);
}
}
$url = "https://".SITE_SERVER_NAME."/regions";
@ -2087,13 +2090,16 @@ file_put_contents("/home/bitrix/www/sitemap.xml", $sitemap_index);
/* sitemap regions file end -------------------------------------------------------------*/
\Bitrix\Main\Mail\Event::send([
if(!in_array("debug", $argv))
{
\Bitrix\Main\Mail\Event::send([
"EVENT_NAME" => "ILSA_UPDATE",
"LID" => "s1",
"C_FIELDS" => Array(
"MESSAGE" => $traceback_message,
)
]);
]);
}
die();