22 public static function send(): void
26 foreach (self::getProviders() as
$provider)
28 $providerCode = $provider::getCode();
31 $sender =
new Sender($providerCode, $payload);
34 static::onSuccessfullySent($providerCode, self::$date);
38 static::createAgent(static::getNextExecutionAgentDate());
22 public static function send(): void {
…}
48 'NAME' =>
'\\'.static::class.
'::send();',
49 'MODULE_ID' =>
'sale',
51 'AGENT_INTERVAL' => 86400,
53 'NEXT_EXEC' => $nextExecutionAgentDate,
62 $date = new \DateTime();
63 $currentMonth = $date->format(
'n');
65 $date->modify(
'+1 day');
66 $modifiedMonth = $date->format(
'n');
68 if ($modifiedMonth > $currentMonth)
72 ->modify(
'first day of '.$date->format(
'F'))
73 ->format(
Main\
Type\DateTime::getFormat())
78 $nextDate = $date->format(
Main\
Type\DateTime::getFormat());
95 private static function getProviders():
array
98 Sale\PaySystem\Internals\Analytics\Provider::class,
99 Sale\Delivery\Internals\Analytics\Provider::class,
100 Sale\Cashbox\Internals\Analytics\Provider::class,
101 Sale\Internals\Analytics\Events\Provider::class,
if(!Loader::includeModule('messageservice')) $provider
static getNextExecutionAgentDate()
static onSuccessfullySent(string $providerCode, Main\Type\DateTime $dateTo)
static createAgent(Main\Type\DateTime $nextExecutionAgentDate)
static getPayloadByCode(string $code, Main\Type\DateTime $dateTo)
static clean(string $providerCode, Main\Type\DateTime $dateTo)
</td ></tr ></table ></td ></tr >< tr >< td class="bx-popup-label bx-width30"><?=GetMessage("PAGE_NEW_TAGS")?> array( $site)