65 if ($fieldID ===
'ROLE')
80 elseif ($fieldID ===
'INITIATED_BY_TYPE')
92 elseif ($fieldID ===
'OWNER')
97 'context' =>
'SONET_GROUP_LIST_FILTER_OWNER',
101 'enableSonetgroups' =>
'N',
102 'allowEmailInvitation' =>
'N',
103 'allowSearchEmailUsers' =>
'N',
104 'departmentSelectDisable' =>
'Y',
108 elseif ($fieldID ===
'MEMBER')
113 'context' =>
'SONET_GROUP_LIST_FILTER_MEMBER',
115 'contextCode' =>
'U',
117 'enableSonetgroups' =>
'N',
118 'allowEmailInvitation' =>
'N',
119 'allowSearchEmailUsers' =>
'N',
120 'departmentSelectDisable' =>
'Y',
124 elseif (in_array($fieldID, [
'FAVORITES',
'EXTRANET' ],
true))
128 '' =>
Loc::getMessage(
'SOCIALNETWORK_WORKGROUP_FILTER_LIST_VALUE_NOT_SPECIFIED'),
133 elseif ($fieldID ===
'COUNTERS')
138 is_array($this->additionalParams)
139 && isset($this->additionalParams[
'MODE'])
146 'NEW_COMMENTS' =>
Loc::getMessage(
'SOCIALNETWORK_WORKGROUP_FILTER_COUNTERS_LIST_VALUE_NEW_COMMENTS'),
147 'PROJECT_NEW_COMMENTS' =>
Loc::getMessage(
'SOCIALNETWORK_WORKGROUP_FILTER_COUNTERS_LIST_VALUE_PROJECT_NEW_COMMENTS'),
153 'EXPIRED' =>
Loc::getMessage(
'SOCIALNETWORK_WORKGROUP_FILTER_COUNTERS_LIST_VALUE_EXPIRED'),
154 'NEW_COMMENTS' =>
Loc::getMessage(
'SOCIALNETWORK_WORKGROUP_FILTER_COUNTERS_LIST_VALUE_NEW_COMMENTS'),
155 'PROJECT_EXPIRED' =>
Loc::getMessage(
'SOCIALNETWORK_WORKGROUP_FILTER_COUNTERS_LIST_VALUE_PROJECT_EXPIRED'),
156 'PROJECT_NEW_COMMENTS' =>
Loc::getMessage(
'SOCIALNETWORK_WORKGROUP_FILTER_COUNTERS_LIST_VALUE_PROJECT_NEW_COMMENTS'),
165 elseif ($fieldID ===
'COMMON_COUNTERS')
170 is_array($this->additionalParams)
171 && isset($this->additionalParams[
'MODE'])
176 CounterFilter::VALUE_LIVEFEED =>
Loc::getMessage(
'SOCIALNETWORK_WORKGROUP_FILTER_COUNTERS_LIST_VALUE_LIVEFEED'),
177 CounterFilter::VALUE_TASKS =>
Loc::getMessage(
'SOCIALNETWORK_WORKGROUP_FILTER_COUNTERS_LIST_VALUE_TASKS'),
199 'options' => [
'type' =>
'number' ],
202 'options' => [
'default' => true ],
205 'options' => [
'type' =>
'dest_selector',
'partial' => true ],
208 'options' => [
'type' =>
'dest_selector',
'partial' => true ],
214 'options' => [
'type' =>
'checkbox' ],
217 'options' => [
'type' =>
'checkbox' ],
220 'conditionMethod' =>
'\Bitrix\Socialnetwork\Filter\WorkgroupDataProvider::getClosedAvailability',
221 'options' => [
'type' =>
'checkbox' ],
224 'conditionMethod' =>
'\Bitrix\Main\Filter\UserDataProvider::getProjectAvailability',
225 'options' => [
'type' =>
'checkbox' ],
228 'conditionMethod' =>
'\Bitrix\Main\Filter\UserDataProvider::getScrumAvailability',
229 'options' => [
'type' =>
'checkbox' ],
232 'conditionMethod' =>
'\Bitrix\Main\Filter\UserDataProvider::getProjectAvailability',
233 'options' => [
'type' =>
'date' ]
236 'conditionMethod' =>
'\Bitrix\Main\Filter\UserDataProvider::getExtranetAvailability',
237 'options' => [
'type' =>
'list',
'partial' => true ],
240 'conditionMethod' =>
'\Bitrix\Main\Filter\UserDataProvider::getLandingAvailability',
241 'options' => [
'type' =>
'checkbox' ],
244 'options' => [
'type' =>
'list',
'partial' => true ],
247 'options' => [
'type' =>
'list',
'partial' => true ],
253 is_array($this->additionalParams)
254 && isset($this->additionalParams[
'MODE'])
258 $fieldsList[
'COMMON_COUNTERS'] = [
259 'options' => [
'type' =>
'list',
'partial' => true ],
263 foreach ($fieldsList as $column => $field)
265 $whiteListPassed =
true;
268 !empty($field[
'conditionMethod'])
269 && is_callable($field[
'conditionMethod'])
272 $whiteListPassed = call_user_func_array($field[
'conditionMethod'], []);
275 if ($whiteListPassed)
278 is_array($this->additionalParams)
279 && isset($this->additionalParams[
'MODE'])
280 && in_array($column, [
'SCRUM',
'PROJECT'],
true)
288 $column ===
'COUNTERS'
290 !is_array($this->additionalParams)
291 || !isset($this->additionalParams[
'MODE'])
300 $column ===
'COMMON_COUNTERS'
302 !isset($this->additionalParams[
'MODE'], $this->additionalParams[
'CONTEXT_USER_ID'])
303 || !is_array($this->additionalParams)
314 (!empty($field[
'options']) ? $field[
'options'] : [])