1C-Bitrix 25.700.0
Загрузка...
Поиск...
Не найдено
marketingservice.php
См. документацию.
1<?php
8
10
14
20{
26 public static function canUse()
27 {
28 if (!Loader::includeModule('seo'))
29 {
30 return false;
31 }
32
34 }
35
41 public static function isAvailable()
42 {
44 }
45
51 public static function getTypeMap()
52 {
53 return [
55 ];
56 }
57
64 public static function getAdsProvider($adsType, $clientId = null)
65 {
67 $service->setClientId($clientId);
68 $providers = Marketing\Configurator::getProviders([$adsType]);
69 $isFound = false;
70 $provider = array();
71 foreach ($providers as $type => $provider)
72 {
73 if ($type == $adsType)
74 {
75 $isFound = true;
76 break;
77 }
78 }
79
80 if (!$isFound)
81 {
82 return null;
83 }
84
85 return $provider;
86 }
87
95 public static function send(\stdClass $config, array $contacts)
96 {
97 if (!static::canUse())
98 {
99 return false;
100 }
101//
102// $audience = Marketing\Service::getAudience($config->type);
103// $audience->setAccountId($config->accountId);
104// $audience->enableQueueMode();
105
106// if ($config->autoRemoveDayNumber)
107// {
108// $audience->enableQueueAutoRemove($config->autoRemoveDayNumber);
109// }
110// else
111// {
112// $audience->disableQueueAutoRemove();
113// }
114//
115// $audienceImportResult = $audience->addContacts(
116// $config->audienceId,
117// $contacts,
118// array(
119// 'type' => $config->contactType
120// )
121// );
122//
123// return $audienceImportResult->isSuccess();
124 return true;
125 }
126}
$type
Определения options.php:106
if(!Loader::includeModule('messageservice')) $provider
Определения callback_ednaruimhpx.php:21
Определения loader.php:13
static send(\stdClass $config, array $contacts)
Определения marketingservice.php:95
static getAdsProvider($adsType, $clientId=null)
Определения marketingservice.php:64
static getService()
Определения configurator.php:45
static getProviders(array $types=null)
Определения configurator.php:67
const TYPE_FACEBOOK
Определения service.php:19
</td ></tr ></table ></td ></tr >< tr >< td class="bx-popup-label bx-width30"><?=GetMessage("PAGE_NEW_TAGS")?> array( $site)
Определения file_new.php:804
Определения account.php:3
$service
Определения payment.php:18
$config
Определения quickway.php:69
$clientId
Определения seo_client.php:18