49 if (($fields[
'ID'] ??
null) && (
int)$fields[
'ID'])
58 if (($fields[
'OWNER_ID'] ??
null) && (
int)$fields[
'OWNER_ID'])
60 $model->setOwnerId($fields[
'OWNER_ID']);
63 if ($fields[
'SECTION_ID'] ??
null)
65 $model->setSectionId((
int)$fields[
'SECTION_ID']);
68 if (($fields[
'CAL_TYPE'] ??
null) && is_string($fields[
'CAL_TYPE']))
70 $model->setSectionType($fields[
'CAL_TYPE']);
73 if (($fields[
'EVENT_TYPE'] ??
null) && is_string($fields[
'EVENT_TYPE']))
75 $model->setEventType($fields[
'EVENT_TYPE']);
78 if (($fields[
'MEETING_STATUS'] ??
null) && is_string($fields[
'MEETING_STATUS']))
80 $model->setMeetingStatus($fields[
'MEETING_STATUS']);
83 if ((
int)($fields[
'PARENT_ID'] ??
null))
85 $model->setParentEventId((
int)$fields[
'PARENT_ID']);
89 (
int)($fields[
'PARENT_ID'] ??
null)
90 && ($fields[
'ID'] ??
null) !== ($fields[
'PARENT_ID'] ??
null)
93 $parentFields = \CCalendarSect::GetSectionByEventId((
int)$fields[
'PARENT_ID']);
94 if ($parentFields && is_array($parentFields))
96 $model->setParentEventSectionFields($parentFields);
99 elseif ((
int)($fields[
'ID'] ??
null) && ($fields[
'ID'] ??
null) === ($fields[
'PARENT_ID'] ??
null))
101 $model->setParentEventSectionFields($fields);