Bitrix-D7
23.9
Загрузка...
Поиск...
Не найдено
calendarevent.php
1
<?php
8
namespace
Bitrix\Socialnetwork\Integration\Calendar
;
9
10
use
Bitrix\Socialnetwork\Livefeed\Provider
;
11
use
Bitrix\Main\Event
;
12
use
Bitrix\Main\EventResult
;
13
14
class
CalendarEvent
15
{
16
public
static
function
onViewEvent
(
Event
$event)
17
{
18
$result =
new
EventResult
(
19
EventResult::UNDEFINED,
20
array(),
21
'socialnetwork'
22
);
23
24
$calendarEventId = $event->
getParameter
(
'eventId'
);
25
26
if
(intval($calendarEventId) <= 0)
27
{
28
return
$result;
29
}
30
31
if
($liveFeedEntity = Provider::init(array(
32
'ENTITY_TYPE'
=> Provider::DATA_ENTITY_TYPE_CALENDAR_EVENT,
33
'ENTITY_ID'
=> $calendarEventId
34
)))
35
{
36
$liveFeedEntity->setContentView();
37
}
38
39
$result =
new
EventResult
(
40
EventResult::SUCCESS,
41
array(),
42
'socialnetwork'
43
);
44
45
return
$result;
46
}
47
}
48
?>
Bitrix\Main\Event
Definition
event.php:5
Bitrix\Main\Event\getParameter
getParameter($key)
Definition
event.php:80
Bitrix\Main\EventResult
Definition
eventresult.php:5
Bitrix\Socialnetwork\Integration\Calendar\CalendarEvent
Definition
calendarevent.php:15
Bitrix\Socialnetwork\Integration\Calendar\CalendarEvent\onViewEvent
static onViewEvent(Event $event)
Definition
calendarevent.php:16
Bitrix\Socialnetwork\Livefeed\Provider
Definition
provider.php:22
Bitrix\Socialnetwork\Integration\Calendar
Definition
apiversion.php:8
modules
socialnetwork
lib
integration
calendar
calendarevent.php
Создано системой
1.10.0