1C-Bitrix 25.700.0
Загрузка...
Поиск...
Не найдено
notify.php
См. документацию.
1<?php
2namespace Bitrix\Im;
3
4use Bitrix\Im\Model\MessageTable;
5use Bitrix\Im\V2\Message;
6use Bitrix\Im\V2\Message\CounterService;
7use Bitrix\Im\V2\Message\Params;
8use Bitrix\Im\V2\Message\ReadService;
9use Bitrix\Im\V2\MessageCollection;
10use Bitrix\Im\V2\Result;
11use Bitrix\Im\V2\Notification\Group\Condition\ConditionFactory;
12use Bitrix\Im\V2\Notification\Group\Condition\Conditions;
13use Bitrix\Main\Type\DateTime;
14use CIMMessageParam;
15use CIMNotify;
16
17class Notify
18{
19 public const
20 EVENT_DEFAULT = 'default',
21 EVENT_SYSTEM = 'system',
22 EVENT_GROUP = 'group',
23 EVENT_PRIVATE = 'private',
24 EVENT_PRIVATE_SYSTEM = 'private_system'
25 ;
26
27 private const CONFIRM_TYPE = 1;
28 private const SIMPLE_TYPE = 3;
29 private const ALL_TYPES = 4;
30
31 private $convertText;
32 private $pageLimit;
33 private $lastType;
34 private $lastId;
35 private $chatId;
36 private $users = [];
37 private $firstPage;
38 private $searchText;
39 private $searchType;
40 private $searchDate;
41 private $totalCount;
42 private string $groupTag;
43 private int $userId;
44 private Conditions $groupConditions;
45
46 public function __construct($options = [])
47 {
48 $this->convertText = $options['CONVERT_TEXT'] ?? null;
49 $this->searchText = $options['SEARCH_TEXT'] ?? null;
50 $this->searchType = $options['SEARCH_TYPE'] ?? null;
51 $this->searchDate = $options['SEARCH_DATE'] ?? null;
52 $this->pageLimit = $options['LIMIT'] ?? null;
53 $this->lastType = $options['LAST_TYPE'] ?? null;
54 $this->lastId = $options['LAST_ID'] ?? null;
55 $this->groupTag = (string)($options['GROUP_TAG'] ?? '');
56 $this->firstPage = !$this->lastId && !$this->lastType;
57 $this->userId = (int)\Bitrix\Im\Common::getUserId();
58
59 $chatData = $this->getChatData();
60 if ($chatData !== null)
61 {
62 $this->chatId = (int)$chatData['CHAT_ID'];
63 $this->totalCount = (int)$chatData['IM_MODEL_RELATION_CHAT_MESSAGE_COUNT'];
64 }
65 }
66
67 private function getChatData(): ?array
68 {
70 if (!$userId)
71 {
72 return null;
73 }
74
75 $chatData = \Bitrix\Im\Model\RelationTable::getList([
76 'select' => ['CHAT_ID', 'CHAT.MESSAGE_COUNT'],
77 'filter' => [
78 '=USER_ID' => $userId,
79 '=MESSAGE_TYPE' => 'S'
80 ]
81 ])->fetch();
82 if (!$chatData)
83 {
84 return null;
85 }
86
87 return $chatData;
88 }
89
90 public static function getRealCounter($chatId): int
91 {
92 return self::getCounters($chatId, true)[$chatId];
93 }
94
95 public static function getRealCounters($chatId)
96 {
97 return self::getCounters($chatId, true);
98 }
99
100 public static function getCounter($chatId): int
101 {
102 return self::getCounters($chatId)[$chatId];
103 }
104
105 public static function getCounters($chatId, $isReal = false)
106 {
107 $result = Array();
108 $chatList = Array();
109 if (is_array($chatId))
110 {
111 foreach($chatId as $id)
112 {
113 $id = intval($id);
114 if ($id)
115 {
116 $result[$id] = 0;
117 $chatList[$id] = $id;
118 }
119 }
120 $chatList = array_values($chatList);
121 $isMulti = count($chatList) > 1;
122 }
123 else
124 {
125 $id = intval($chatId);
126 if ($id)
127 {
128 $result[$id] = 0;
129 $chatList[] = $id;
130 }
131 $isMulti = false;
132 }
133
134 if (!$chatList)
135 {
136 return false;
137 }
138
139 /*if ($isReal)
140 {
141 $query = "
142 SELECT CHAT_ID, COUNT(1) COUNTER
143 FROM b_im_message
144 WHERE CHAT_ID ".($isMulti? ' IN ('.implode(',', $chatList).')': ' = '.$chatList[0])."
145 AND NOTIFY_READ = 'N'
146 GROUP BY CHAT_ID
147 ";
148 }
149 else
150 {
151 $query = "
152 SELECT CHAT_ID, COUNTER
153 FROM b_im_relation
154 WHERE CHAT_ID ".($isMulti? ' IN ('.implode(',', $chatList).')': ' = '.$chatList[0])."
155 ";
156 }*/
157
158 /*$orm = \Bitrix\Main\Application::getInstance()->getConnection()->query($query);
159 while($row = $orm->fetch())
160 {
161 $result[$row['CHAT_ID']] = (int)$row['COUNTER'];
162 }*/
163
164 if ($isMulti)
165 {
166 $result = (new CounterService(Common::getUserId()))->getForNotifyChats($chatList);
167 }
168 else
169 {
170 $counter = (new CounterService(Common::getUserId()))->getByChat($chatList[0]);
171 $result[$chatList[0]] = $counter;
172 }
173
174 return $result;
175 }
176
177 public function get()
178 {
179 if (!$this->chatId || !$this->totalCount)
180 {
181 return [
182 'notifications' => [],
183 'users' => [],
184 ];
185 }
186 // fetching confirm notifications
187 $confirmCollection = $this->fetchConfirms();
188
189 // fetching simple notifications
190 $offset = count($confirmCollection);
191 $simpleCollection = $this->fetchSimple($offset);
192 $notifications = array_merge($confirmCollection, $simpleCollection);
193
194 /*$unreadCount = \Bitrix\Im\Model\MessageTable::getList(
195 [
196 'select' => ['CNT'],
197 'filter' => [
198 '=CHAT_ID' => $this->chatId,
199 '=NOTIFY_READ' => 'N'
200 ],
201 'runtime' => [
202 new \Bitrix\Main\ORM\Fields\ExpressionField('CNT', 'COUNT(*)')
203 ]
204 ]
205 )->fetch();*/
206
207 $unreadCount = (new CounterService(\Bitrix\Im\Common::getUserId()))->getByChat($this->chatId);
208
209 $result = [
210 'TOTAL_COUNT' => $this->totalCount,
211 'TOTAL_UNREAD_COUNT' => (int)$unreadCount,
212 'CHAT_ID' => $this->chatId,
213 'NOTIFICATIONS' => $notifications,
214 'USERS' => $this->users,
215 ];
216
217 foreach ($result['NOTIFICATIONS'] as $key => $value)
218 {
219 if ($value['DATE'] instanceof DateTime)
220 {
221 $result['NOTIFICATIONS'][$key]['DATE'] = date('c', $value['DATE']->getTimestamp());
222 }
223
224 $result['NOTIFICATIONS'][$key] = array_change_key_case($result['NOTIFICATIONS'][$key], CASE_LOWER);
225 }
226 $result['NOTIFICATIONS'] = array_values($result['NOTIFICATIONS']);
227 $result['USERS'] = array_values($result['USERS']);
228 $result = array_change_key_case($result, CASE_LOWER);
229
230 return $result;
231 }
232
233 private function requestData(int $requestType, int $limit): array
234 {
235 $collection = [];
236 $ormParams = $this->prepareGettingIdParams($requestType, $limit);
237 $ids = \Bitrix\Im\Model\MessageTable::getList($ormParams)->fetchAll();
238 if (count($ids) === 0)
239 {
240 return $collection;
241 }
242
243 $ids = array_map(static function($item) {
244 return (int)$item['ID'];
245 }, $ids);
246
247 $ormParams = $this->prepareFilteringByIdParams($ids);
248 $ormResult = \Bitrix\Im\Model\MessageTable::getList($ormParams);
249
250 foreach ($ormResult as $notifyItem)
251 {
252 if ($notifyItem['NOTIFY_EVENT'] === self::EVENT_PRIVATE_SYSTEM)
253 {
254 $notifyItem['AUTHOR_ID'] = 0;
255 }
256
257 $collection[$notifyItem['ID']] = [
258 'ID' => (int)$notifyItem['ID'],
259 'CHAT_ID' => $this->chatId,
260 'AUTHOR_ID' => (int)$notifyItem['AUTHOR_ID'],
261 'DATE' => $notifyItem['DATE_CREATE'],
262 'NOTIFY_TYPE' => (int)$notifyItem['NOTIFY_TYPE'],
263 'NOTIFY_MODULE' => $notifyItem['NOTIFY_MODULE'],
264 'NOTIFY_EVENT' => $notifyItem['NOTIFY_EVENT'],
265 'NOTIFY_TAG' => $notifyItem['NOTIFY_TAG'],
266 'NOTIFY_SUB_TAG' => $notifyItem['NOTIFY_SUB_TAG'],
267 'NOTIFY_TITLE' => $notifyItem['NOTIFY_TITLE'],
268 //'NOTIFY_READ' => $notifyItem['NOTIFY_READ'],
269 'SETTING_NAME' => $notifyItem['NOTIFY_MODULE'].'|'.$notifyItem['NOTIFY_EVENT'],
270 ];
271 $collection[$notifyItem['ID']]['TEXT'] = \Bitrix\Im\Text::parse(
272 \Bitrix\Im\Text::convertHtmlToBbCode($notifyItem['MESSAGE']),
273 ['LINK_TARGET_SELF' => 'Y']
274 );
275 if ($notifyItem['AUTHOR_ID'] && !isset($this->users[$notifyItem['AUTHOR_ID']]))
276 {
277 $user = User::getInstance($notifyItem['AUTHOR_ID'])->getArray([
278 'JSON' => 'Y',
279 'SKIP_ONLINE' => 'Y'
280 ]);
281 $user['last_activity_date'] =
282 $notifyItem['USER_LAST_ACTIVITY_DATE']
283 ? date('c', $notifyItem['USER_LAST_ACTIVITY_DATE']->getTimestamp())
284 : false
285 ;
286 $user['desktop_last_date'] = false;
287 $user['mobile_last_date'] = false;
288 $user['idle'] = false;
289
290 $this->users[$notifyItem['AUTHOR_ID']] = $user;
291 }
292
293 //keyboard creation
294 if ($notifyItem['NOTIFY_BUTTONS'])
295 {
296 $buttons = unserialize($notifyItem['NOTIFY_BUTTONS'], ['allowed_classes' => false]);
297
298 $keyboard = new \Bitrix\Im\Bot\Keyboard(111);
299 $command = 'notifyConfirm';
300 foreach ($buttons as $button)
301 {
302 $keyboard->addButton(
303 [
304 'TEXT' => $button['TITLE'],
305 'COMMAND' => $command,
306 'COMMAND_PARAMS' => $notifyItem['ID'].'|'.$button['VALUE'],
307 'TEXT_COLOR' => '#fff',
308 'BG_COLOR' => $button['TYPE'] === 'accept' ? '#8BC84B' : '#ef4b57',
309 'DISPLAY' => 'LINE'
310 ]
311 );
312 }
313 $collection[$notifyItem['ID']]['NOTIFY_BUTTONS'] = $keyboard->getJson();
314 }
315 }
316
317 if (count($collection) > 0)
318 {
319 $params = \CIMMessageParam::Get(array_keys($collection));
320 foreach ($params as $notificationId => $param)
321 {
322 $collection[$notificationId]['PARAMS'] = empty($param) ? null : $param;
323 }
324
325 $collection = $this->fillReadStatuses($collection);
326 }
327
328 return $collection;
329 }
330
331 private function fetchConfirms(): array
332 {
333 $confirmCollection = [];
334
335 $nextPageIsConfirm = $this->lastType === self::CONFIRM_TYPE;
336 if ($this->firstPage || $nextPageIsConfirm)
337 {
338 $confirmCollection = $this->requestData(self::CONFIRM_TYPE, $this->pageLimit);
339 }
340
341 return $confirmCollection;
342 }
343
344 private function fetchSimple(int $offset): array
345 {
346 $simpleCollection = [];
347 $nextPageIsSimple = $this->lastType === self::SIMPLE_TYPE;
348 $needMoreOnFirstPage = $this->firstPage && $offset < $this->pageLimit;
349 $notEnoughFromPreviousStep = $this->lastType === self::CONFIRM_TYPE && $offset < $this->pageLimit;
350
351 if ($needMoreOnFirstPage || $notEnoughFromPreviousStep || $nextPageIsSimple)
352 {
353 $simpleCollection = $this->requestData(self::SIMPLE_TYPE, $this->pageLimit - $offset);
354 }
355
356 return $simpleCollection;
357 }
358
359 public function search(): array
360 {
361 if (!$this->chatId)
362 {
363 return [];
364 }
365
366 if (!$this->searchText && !$this->searchType && !$this->searchDate)
367 {
368 return [];
369 }
370
371 if ($this->lastId > 0)
372 {
373 $this->lastType = self::ALL_TYPES;
374 $this->firstPage = false;
375 }
376
377 // fetching searched notifications
378 $collection = $this->requestData(self::ALL_TYPES, $this->pageLimit);
379
380 $result = [
381 'CHAT_ID' => $this->chatId,
382 'NOTIFICATIONS' => $collection,
383 'USERS' => $this->users,
384 ];
385
386 if (!$this->lastId)
387 {
388 $result['TOTAL_RESULTS'] = $this->requestSearchTotalCount();
389 }
390
391 foreach ($result['NOTIFICATIONS'] as $key => $value)
392 {
393 if ($value['DATE'] instanceof DateTime)
394 {
395 $result['NOTIFICATIONS'][$key]['DATE'] = date('c', $value['DATE']->getTimestamp());
396 }
397
398 $result['NOTIFICATIONS'][$key] = array_change_key_case($result['NOTIFICATIONS'][$key], CASE_LOWER);
399 }
400 $result['NOTIFICATIONS'] = array_values($result['NOTIFICATIONS']);
401 $result['USERS'] = array_values($result['USERS']);
402 $result = array_change_key_case($result, CASE_LOWER);
403
404 return $result;
405 }
406
412 public static function cleanNotifyAgent(): string
413 {
414 $dayCount = 60;
415 $limit = 2000;
416 $step = 1000;
417
418 $batches = [];
419 $result = \Bitrix\Im\Model\MessageTable::getList([
420 'select' => ['ID', 'CHAT_ID'],
421 'filter' => [
423 '<DATE_CREATE' => ConvertTimeStamp((time() - 86400 * $dayCount), 'FULL')
424 ],
425 'limit' => $limit
426 ]);
427
428 $batch = new MessageCollection();
429 $i = 0;
430
431 while ($row = $result->fetch())
432 {
433 if ($i++ === $step)
434 {
435 $i = 0;
436 $batches[] = $batch;
437 $batch = new MessageCollection();
438 }
439
440 $message = (new Message())->setMessageId((int)$row['ID'])->setChatId((int)$row['CHAT_ID']);
441 $batch->add($message);
442 }
443 if ($batch->count() !== 0)
444 {
445 $batches[] = $batch;
446 }
447
448 $counterService = new CounterService();
449 foreach ($batches as $batch)
450 {
451 $messageIds = $batch->getIds();
452 if (empty($messageIds))
453 {
454 continue;
455 }
457 '=ID' => $messageIds
458 ]);
460 '=MESSAGE_ID' => $messageIds
461 ]);
462 $counterService->deleteByMessagesForAll($batch);
463 }
464
465 return __METHOD__. '();';
466 }
467
468 private function requestSearchTotalCount(): int
469 {
470 return \Bitrix\Im\Model\MessageTable::getCount($this->getFilterConditions());
471 }
472
482 private function prepareGettingIdParams(int $requestType, int $limit): array
483 {
484 return [
485 'select' => ['ID'],
486 'filter' => $this->getFilterConditions($requestType, true),
487 'order' => ['DATE_CREATE' => 'DESC', 'ID' => 'DESC'],
488 'limit' => $limit
489 ];
490 }
491
492 private function getFilterConditions(int $requestType = self::ALL_TYPES, bool $withIdCondition = false): array
493 {
494 $filter = [
495 '=CHAT_ID' => $this->chatId,
496 ];
497
498 if ($requestType === self::CONFIRM_TYPE)
499 {
500 $filter['=NOTIFY_TYPE'] = IM_NOTIFY_CONFIRM;
501 }
502 elseif ($requestType === self::SIMPLE_TYPE)
503 {
504 $filter['!=NOTIFY_TYPE'] = IM_NOTIFY_CONFIRM;
505 }
506 elseif ($requestType === self::ALL_TYPES)
507 {
508 if ($this->searchText)
509 {
510 $filter['*%MESSAGE'] = $this->searchText;
511 }
512 if ($this->searchType)
513 {
514 $options = explode('|', $this->searchType);
515 $filter['=NOTIFY_MODULE'] = $options[0];
516 if (isset($options[1]))
517 {
518 $filter['=NOTIFY_EVENT'] = $options[1];
519 }
520 }
521 if ($this->searchDate)
522 {
523 $dateStart = new DateTime(
524 $this->searchDate,
525 \DateTimeInterface::RFC3339,
526 new \DateTimeZone('UTC')
527 );
528 $dateEnd = (
529 new DateTime(
530 $this->searchDate,
531 \DateTimeInterface::RFC3339,
532 new \DateTimeZone('UTC')
533 )
534 )->add('1 DAY');
535 $filter['><DATE_CREATE'] = [$dateStart, $dateEnd];
536 }
537
538 if ($this->groupTag)
539 {
540 $filter = array_merge($filter, $this->getGroupConditions()->toFilterFormat());
541 }
542 }
543
544 if ($withIdCondition && !$this->firstPage)
545 {
546 if (
547 $requestType === self::CONFIRM_TYPE
548 || ($requestType === self::SIMPLE_TYPE && $this->lastType === self::SIMPLE_TYPE)
549 || ($requestType === self::ALL_TYPES && $this->lastType === self::ALL_TYPES)
550 )
551 {
552 $filter['<ID'] = $this->lastId;
553 }
554 }
555
556 return $filter;
557 }
558
566 private function prepareFilteringByIdParams(array $ids): array
567 {
568 return [
569 'select' => [
570 'ID',
571 'AUTHOR_ID',
572 'MESSAGE',
573 'DATE_CREATE',
574 'NOTIFY_TYPE',
575 'NOTIFY_EVENT',
576 'NOTIFY_MODULE',
577 'NOTIFY_TAG',
578 'NOTIFY_SUB_TAG',
579 'NOTIFY_TITLE',
580 //'NOTIFY_READ',
581 'NOTIFY_BUTTONS',
582 'USER_LAST_ACTIVITY_DATE' => 'AUTHOR.LAST_ACTIVITY_DATE',
583 //'USER_IDLE' => 'STATUS.IDLE',
584 //'USER_MOBILE_LAST_DATE' => 'STATUS.MOBILE_LAST_DATE',
585 //'USER_DESKTOP_LAST_DATE' => 'STATUS.DESKTOP_LAST_DATE',
586 ],
587 'filter' => ['=ID' => $ids],
588 'order' => ['DATE_CREATE' => 'DESC', 'ID' => 'DESC'],
589 ];
590 }
591
592 public function getLastId(): ?int
593 {
594 if (!$this->chatId)
595 {
596 return null;
597 }
598
599 $ormParams = [
600 'select' => ['ID'],
601 'filter' => ['=CHAT_ID' => $this->chatId],
602 'order' => ['DATE_CREATE' => 'DESC', 'ID' => 'DESC'],
603 'limit' => 1,
604 ];
605
606 $getListResult = \Bitrix\Im\Model\MessageTable::getList($ormParams)->fetch();
607 if (!$getListResult)
608 {
609 return null;
610 }
611
612 if (count($getListResult) === 1)
613 {
614 return (int)$getListResult['ID'];
615 }
616
617 return null;
618 }
619
620 private function fillReadStatuses(array $notifications): array
621 {
622 $messageIds = array_keys($notifications);
623
624 $readStatuses = (new ReadService(\Bitrix\Im\Common::getUserId()))->getReadStatusesByMessageIds($messageIds);
625
626 foreach ($notifications as $id => $notification)
627 {
628 $notifications[$id]['NOTIFY_READ'] = $readStatuses[$id] ? 'Y' : 'N';
629 }
630
631 return $notifications;
632 }
633
634 private function getGroupConditions(): Conditions
635 {
636 if (!isset($this->groupConditions))
637 {
638 $this->groupConditions = (new ConditionFactory())->makeByTag($this->groupTag, $this->userId);
639 }
640
641 return $this->groupConditions;
642 }
643
644 public static function deleteOldNotifyByTag(int $currentMessageId, array $arParams): Result
645 {
646 $result = new Result();
647 $notifyTag = (string)$arParams['NOTIFY_TAG'];
648 $chatId = (int)$arParams['CHAT_ID'];
649
650 if (!$notifyTag || $chatId <= 0)
651 {
652 return $result;
653 }
654
655 $query = MessageTable::query()
656 ->setSelect(['ID', 'AUTHOR_ID', 'CHAT_ID'])
657 ->where('NOTIFY_TAG', $notifyTag)
658 ;
659
660 if ((int)$arParams['NOTIFY_TYPE'] !== IM_NOTIFY_CONFIRM)
661 {
662 $query->where('CHAT_ID', $chatId);
663 }
664
665 $query = $query->exec();
666
667 $messages = [];
668 $messageIds = [];
669 $maxId = 0;
670
671 while ($row = $query->fetch())
672 {
673 $messageId = (int)$row['ID'];
674 $messageIds[$messageId] = $messageId;
675
676 if ((int)$row['CHAT_ID'] !== $chatId)
677 {
678 continue;
679 }
680
682 'ID' => $messageId,
683 'AUTHOR_ID' => (int)$row['AUTHOR_ID'],
684 'CHAT_ID' => (int)$row['CHAT_ID'],
685 ];
686
687 if ($messageId > $maxId)
688 {
689 $maxId = $messageId;
690 $maxAuthorId = (int)$row['AUTHOR_ID'];
691 }
692 }
693
694 $params = self::getUsersParam(array_keys($messages));
695 $newParams = [];
696 foreach ($messages as $message)
697 {
698 $newParams[$message['AUTHOR_ID']] = (int)$message['AUTHOR_ID'];
699
700 foreach ($params[$message['ID']] ?? [] as $param)
701 {
702 $newParams[$param] = (int)$param;
703 }
704 }
705
706 $newParams = array_diff($newParams, $params[$maxId] ?? []);
707
708 unset($messageIds[$maxId]);
709 CIMNotify::deleteList($messageIds, ['NOTIFY_TAG' => $notifyTag]);
710
711 if ($currentMessageId >= $maxId)
712 {
713 unset($newParams[$arParams['AUTHOR_ID']]);
714 }
715 else
716 {
717 unset($newParams[$maxAuthorId ?? 0]);
718 self::saveNotifyParams($maxId, ['USERS' => array_values($newParams)]);
719 }
720
721 return $currentMessageId < $maxId ? $result : $result->setResult(array_values($newParams));
722 }
723
724 private static function getUsersParam(array $messageIds): array
725 {
726 if (empty($messageIds))
727 {
728 return [];
729 }
730
731 $query = \Bitrix\Im\Model\MessageParamTable::query()
732 ->setSelect(['MESSAGE_ID', 'PARAM_VALUE'])
733 ->whereIn('MESSAGE_ID', $messageIds)
734 ->where('PARAM_NAME', Params::USERS)
735 ->exec()
736 ;
737
738 $params = [];
739 while ($row = $query->fetch())
740 {
741 $params[$row['MESSAGE_ID']][(int)$row['PARAM_VALUE']] = (int)$row['PARAM_VALUE'];
742 }
743
744 return $params;
745 }
746
747 public static function saveNotifyParams(int $messageId, array $values): void
748 {
749 $params = (new Params())->setMessageId($messageId);
750 $params->load($values);
751 $params->save();
752 }
753}
$arParams
Определения access_dialog.php:21
if(! $messageFields||!isset($messageFields['message_id'])||!isset($messageFields['status'])||!CModule::IncludeModule("messageservice")) $messageId
Определения callback_ismscenter.php:26
if(!is_object($USER)||! $USER->IsAuthorized()) $userId
Определения check_mail.php:18
static getUserId($userId=null)
Определения common.php:73
static deleteBatch(array $filter)
Определения messageparam.php:120
static deleteBatch(array $filter)
Определения message.php:353
Определения notify.php:18
static getRealCounters($chatId)
Определения notify.php:95
const EVENT_PRIVATE_SYSTEM
Определения notify.php:24
const EVENT_DEFAULT
Определения notify.php:20
const EVENT_PRIVATE
Определения notify.php:23
search()
Определения notify.php:359
static cleanNotifyAgent()
Определения notify.php:412
static saveNotifyParams(int $messageId, array $values)
Определения notify.php:747
const EVENT_GROUP
Определения notify.php:22
static getCounters($chatId, $isReal=false)
Определения notify.php:105
__construct($options=[])
Определения notify.php:46
getLastId()
Определения notify.php:592
static deleteOldNotifyByTag(int $currentMessageId, array $arParams)
Определения notify.php:644
static getCounter($chatId)
Определения notify.php:100
static getRealCounter($chatId)
Определения notify.php:90
const EVENT_SYSTEM
Определения notify.php:21
static convertHtmlToBbCode($html)
Определения text.php:398
static getInstance($userId=null)
Определения user.php:45
Определения result.php:20
if(!\Bitrix\Main\Loader::includeModule('clouds')) $lastId
Определения sync.php:68
$options
Определения commerceml2.php:49
</td ></tr ></table ></td ></tr >< tr >< td class="bx-popup-label bx-width30"><?=GetMessage("PAGE_NEW_TAGS")?> array( $site)
Определения file_new.php:804
$result
Определения get_property_values.php:14
$query
Определения get_search.php:11
$filter
Определения iblock_catalog_list.php:54
const IM_NOTIFY_SYSTEM
Определения include.php:38
const IM_NOTIFY_CONFIRM
Определения include.php:36
const IM_NOTIFY_FROM
Определения include.php:37
Определения Uuid.php:3
$user
Определения mysql_to_pgsql.php:33
$message
Определения payment.php:8
$counter
Определения options.php:5
return false
Определения prolog_main_admin.php:185
if( $daysToExpire >=0 &&$daysToExpire< 60 elseif)( $daysToExpire< 0)
Определения prolog_main_admin.php:393
if(empty($signedUserToken)) $key
Определения quickway.php:257
$i
Определения factura.php:643
</p ></td >< td valign=top style='border-top:none;border-left:none;border-bottom:solid windowtext 1.0pt;border-right:solid windowtext 1.0pt;padding:0cm 2.0pt 0cm 2.0pt;height:9.0pt'>< p class=Normal align=center style='margin:0cm;margin-bottom:.0001pt;text-align:center;line-height:normal'>< a name=ТекстовоеПоле54 ></a ><?=($taxRate > count( $arTaxList) > 0) ? $taxRate."%"
Определения waybill.php:936
$messages
Определения template.php:8
if($inWords) echo htmlspecialcharsbx(Number2Word_Rus(roundEx($totalVatSum $params['CURRENCY']
Определения template.php:799
$totalCount
Определения subscription_card_product.php:51