36 $contentEntityId = intval($event->
getParameter(
'entityId'));
40 || !in_array($contentTypeId, self::getContentTypeIdList())
41 || $contentEntityId <= 0
48 if ($contentTypeId == self::CONTENT_TYPE_ID_COMMENT)
50 $res = MessageTable::getList([
52 '=ID' => $contentEntityId
54 'select' => [
'XML_ID' ]
56 if ($message = $res->fetch())
58 if (preg_match(
"/^TASK_(.+)\$/", $message[
"XML_ID"], $match))
60 $taskId = intval($match[1]);
63 'forum',
'onTaskCommentContentViewed',
67 'commentId' => $contentEntityId
72 $subTagList[] =
"TASKS|COMMENT|".$taskId.
'|'.$userId.
'|'.$contentEntityId.
'|TASK_UPDATE';
76 $subTagList[] =
"FORUM|COMMENT|".$contentEntityId.
'|'.$userId;
82 Loader::includeModule(
'im')
83 && !empty($subTagList)
86 $CIMNotify = new \CIMNotify();
87 $CIMNotify->markNotifyReadBySubTag($subTagList);