1C-Bitrix 25.700.0
Загрузка...
Поиск...
Не найдено
Класс Options

Открытые члены

 __construct ($filterId, $filterPresets=[], $commonPresetsId=null)
 getCommonPresetsId ()
 isUseCommonPresets ()
 getId ()
 setPresets ($presets=[])
 setCurrentPreset ($presetId="default_filter")
 getDefaultPresets ()
 getPresets ()
 setDefaultPreset ($presetId="default_filter")
 isUsePinPreset ()
 setDefaultPresets ($presets=[])
 setDeletedPresets ($deletedPresets=[])
 setUsePinPreset ($value=true)
 fetchOptions ($id)
 getOptions ()
 pinPreset ($presetId="default_filter")
 getSessionFilterId ()
 isSetOutside ()
 getAdditionalPresetFields ($presetId)
 setAdditionalPresetFields ($presetId, $additional=[])
 getDefaultFilterId ()
 getCurrentFilterId ()
 getFilterSettings ($presetId)
 getFilter ($sourceFields=[])
 getFilterLogic ($sourceFields=[])
 getSearchString ()
 save ()
 getAllUserOptions ()
 saveForAll ()
 saveOptionsForUser ($options, $userId)
 saveCommon ()
 setFilterRows ($presetId, $rows)
 removeRowFromPreset (string $presetId, string $rowName)
 restore ($settings=[])
 setFilterSettingsArray ($settings=[])
 setFilterSettings ($presetId, $settings, $currentPreset=true, $useRequest=true)
 deleteFilter ($presetId, $isDefault=false)
 isDeletedPreset ($presetId)
 setupDefaultFilter (array $fields, array $rows)
 reset ()
 destroy ()
 getUsedFields ()
 getCurrentFilterPresetId ()
 setCurrentFilterPresetId (?string $presetId)

Открытые статические члены

static fetchCommonPresets ($id)
static findDefaultPresetId ($presets=[])
static isSetFromRequest (HttpRequest $request)
static fetchSettingsFromQuery ($fields, HttpRequest $request)
static isDateField ($key="")
static fetchDateFieldValue ($key="", $filterFields=[])
static fetchNumberFieldValue ($key="", $filterFields=[])
static isNumberField ($key="")
static fetchFieldValuesFromFilterSettings ($filterSettings=[], $additionalFields=[], $sourceFields=[])
static isDefaultFilter ($presetId="")
static isCurrentUserEditOtherSettings ()
static isCommon ($options)
static calcDates ($fieldId, $source, &$result)
static getRowsFromFields ($fields=[])
static fetchPresetFields ($preset)

Поля данных

const DEFAULT_FILTER = "default_filter"
const TMP_FILTER = "tmp_filter"

Защищенные члены

 getRequest ()
 getStorage ()
 trySetFilterFromRequest ($fields=[])

Защищенные статические члены

static fetchFieldsFromFilterSettings ($filterSettings=[], $additionalFields=[])

Защищенные данные

 $id
 $options
 $commonPresets
 $useCommonPresets
 $commonPresetsId
 $request
string $currentFilterPresetId = null

Подробное описание

См. определение в файле options.php строка 15

Конструктор(ы)

◆ __construct()

__construct ( $filterId,
$filterPresets = [],
$commonPresetsId = null )

Options constructor.

Аргументы
string$filterId$arParams["FILTER_ID"]
array$filterPresets$arParams["FILTER_PRESETS"]
string$commonPresetsId$arParams["COMMON_PRESETS_ID"] Set if you want to use common presets

См. определение в файле options.php строка 34

Методы

◆ calcDates()

calcDates ( $fieldId,
$source,
& $result )
static

Calculate date value

Аргументы
string$fieldId
array$sourceSource values
array$resultResult values
Исключения

Bitrix\Main\ObjectException

См. определение в файле options.php строка 1223

◆ deleteFilter()

deleteFilter ( $presetId,
$isDefault = false )

Deletes preset by preset id

Аргументы
string$presetId
bool$isDefault

См. определение в файле options.php строка 1184

◆ destroy()

destroy ( )

Destroys this filter options

См. определение в файле options.php строка 1624

◆ fetchCommonPresets()

fetchCommonPresets ( $id)
static

Gets common presets from database

Аргументы
string$idCommon presets id $arParams["COMMON_PRESETS_ID"]
Возвращает
array|bool

См. определение в файле options.php строка 233

◆ fetchDateFieldValue()

fetchDateFieldValue ( $key = "",
$filterFields = [] )
static

Fetches date field values

Аргументы
string$key
array$filterFields
Возвращает
array
Исключения

Bitrix\Main\ObjectException

См. определение в файле options.php строка 613

◆ fetchFieldsFromFilterSettings()

fetchFieldsFromFilterSettings ( $filterSettings = [],
$additionalFields = [] )
staticprotected

Fetches filter fields from filter settings

Аргументы
array$filterSettings
array$additionalFields
Возвращает
array

См. определение в файле options.php строка 577

◆ fetchFieldValuesFromFilterSettings()

fetchFieldValuesFromFilterSettings ( $filterSettings = [],
$additionalFields = [],
$sourceFields = [] )
static

См. определение в файле options.php строка 670

◆ fetchNumberFieldValue()

fetchNumberFieldValue ( $key = "",
$filterFields = [] )
static

Fetches number field values

Аргументы
string$key
array$filterFields
Возвращает
array

См. определение в файле options.php строка 639

◆ fetchOptions()

fetchOptions ( $id)

Gets filter options from database

Аргументы
string$idFilter id $arParams["FILTER_ID"]
Возвращает
array|bool

См. определение в файле options.php строка 247

◆ fetchPresetFields()

fetchPresetFields ( $preset)
static

Fetches preset fields list

Аргументы
array$preset
Возвращает
array

См. определение в файле options.php строка 1674

◆ fetchSettingsFromQuery()

fetchSettingsFromQuery ( $fields,
HttpRequest $request )
static

Fetches field values from request

Аргументы
array$fields
HttpRequest$request
Возвращает
array|null

См. определение в файле options.php строка 357

◆ findDefaultPresetId()

findDefaultPresetId ( $presets = [])
static

Finds default preset in presets array

Аргументы
array$presets
Возвращает
string Default preset id

См. определение в файле options.php строка 291

◆ getAdditionalPresetFields()

getAdditionalPresetFields ( $presetId)

Gets additional preset fields

Аргументы
string$presetId
Возвращает
array

См. определение в файле options.php строка 501

◆ getAllUserOptions()

getAllUserOptions ( )

Gets filter options for all users

Возвращает
bool|\CDBResult

См. определение в файле options.php строка 825

◆ getCommonPresetsId()

getCommonPresetsId ( )
Возвращает
string

См. определение в файле options.php строка 125

◆ getCurrentFilterId()

getCurrentFilterId ( )

Gets current applied filter id

Возвращает
mixed

См. определение в файле options.php строка 535

◆ getCurrentFilterPresetId()

getCurrentFilterPresetId ( )
Возвращает
string|null

См. определение в файле options.php строка 1726

◆ getDefaultFilterId()

getDefaultFilterId ( )

Gets default filter

Возвращает
mixed

См. определение в файле options.php строка 526

◆ getDefaultPresets()

getDefaultPresets ( )

Gets default presets from filter options

Возвращает
array|null

См. определение в файле options.php строка 169

◆ getFilter()

getFilter ( $sourceFields = [])

Gets current filter values

Аргументы
array$sourceFieldsFilter fields $arParams["FILTER"]
Возвращает
array

См. определение в файле options.php строка 735

◆ getFilterLogic()

getFilterLogic ( $sourceFields = [])

Gets current filter values that available for DB seach

Аргументы
array$sourceFieldsFilter fields $arParams["FILTER"]
Возвращает
array

См. определение в файле options.php строка 766

◆ getFilterSettings()

getFilterSettings ( $presetId)

Gets filter settings by preset id

Аргументы
$presetId
Возвращает
array|null

См. определение в файле options.php строка 566

◆ getId()

getId ( )

Gets filter id

Возвращает
string

См. определение в файле options.php строка 142

◆ getOptions()

getOptions ( )

Gets filter options

Возвращает
array

См. определение в файле options.php строка 313

◆ getPresets()

getPresets ( )

Gets presets

Возвращает
array|null

См. определение в файле options.php строка 178

◆ getRequest()

getRequest ( )
protected

См. определение в файле options.php строка 276

◆ getRowsFromFields()

getRowsFromFields ( $fields = [])
static

См. определение в файле options.php строка 1635

◆ getSearchString()

getSearchString ( )

Gets filter search string

Возвращает
string

См. определение в файле options.php строка 781

◆ getSessionFilterId()

getSessionFilterId ( )

Gets session filter

Возвращает
mixed

См. определение в файле options.php строка 479

◆ getStorage()

getStorage ( )
protected

См. определение в файле options.php строка 281

◆ getUsedFields()

getUsedFields ( )

Gets used fields

Возвращает
array

См. определение в файле options.php строка 1689

◆ isCommon()

isCommon ( $options)
static

Checks whether the parameters are common

Аргументы
$options
Возвращает
bool

См. определение в файле options.php строка 895

◆ isCurrentUserEditOtherSettings()

isCurrentUserEditOtherSettings ( )
static
Возвращает
bool

См. определение в файле options.php строка 833

◆ isDateField()

isDateField ( $key = "")
static
Аргументы
string$key
Возвращает
bool

См. определение в файле options.php строка 601

◆ isDefaultFilter()

isDefaultFilter ( $presetId = "")
static
Аргументы
string$presetId
Возвращает
bool

См. определение в файле options.php строка 725

◆ isDeletedPreset()

isDeletedPreset ( $presetId)

Checks preset is deleted

Аргументы
string$presetId
Возвращает
bool

См. определение в файле options.php строка 1199

◆ isNumberField()

isNumberField ( $key = "")
static

См. определение в файле options.php строка 665

◆ isSetFromRequest()

isSetFromRequest ( HttpRequest $request)
static

Checks is need whether to set fields from query

Аргументы
HttpRequest$request
Возвращает
bool

См. определение в файле options.php строка 342

◆ isSetOutside()

isSetOutside ( )

См. определение в файле options.php строка 486

◆ isUseCommonPresets()

isUseCommonPresets ( )
Возвращает
bool

См. определение в файле options.php строка 133

◆ isUsePinPreset()

isUsePinPreset ( )

Checks is need use pinned preset

Возвращает
bool

См. определение в файле options.php строка 196

◆ pinPreset()

pinPreset ( $presetId = "default_filter")

Makes preset as default

Аргументы
string$presetIdPreset id

См. определение в файле options.php строка 322

◆ removeRowFromPreset()

removeRowFromPreset ( string $presetId,
string $rowName )

См. определение в файле options.php строка 981

◆ reset()

reset ( )

Resets current applied filter

См. определение в файле options.php строка 1615

◆ restore()

restore ( $settings = [])

Restores filter options to default

Аргументы
array$settings

См. определение в файле options.php строка 1005

◆ save()

save ( )

Saves filter optionsGet

См. определение в файле options.php строка 793

◆ saveCommon()

saveCommon ( )

Saves current options as common

См. определение в файле options.php строка 937

◆ saveForAll()

saveForAll ( )

Saves filter options for all users

См. определение в файле options.php строка 842

◆ saveOptionsForUser()

saveOptionsForUser ( $options,
$userId )

Saves options for user with $userId

Аргументы
array$options
$userId

См. определение в файле options.php строка 905

◆ setAdditionalPresetFields()

setAdditionalPresetFields ( $presetId,
$additional = [] )

Sets additional fields

Аргументы
string$presetId
array$additional

См. определение в файле options.php строка 515

◆ setCurrentFilterPresetId()

setCurrentFilterPresetId ( ?string $presetId)
Аргументы
string | null$presetId
Возвращает
Options

См. определение в файле options.php строка 1735

◆ setCurrentPreset()

setCurrentPreset ( $presetId = "default_filter")

Sets current preset id

Аргументы
string$presetId

См. определение в файле options.php строка 160

◆ setDefaultPreset()

setDefaultPreset ( $presetId = "default_filter")

Sets default preset id

Аргументы
string$presetId

См. определение в файле options.php строка 187

◆ setDefaultPresets()

setDefaultPresets ( $presets = [])

Sets default presets

Аргументы
array$presets

См. определение в файле options.php строка 205

◆ setDeletedPresets()

setDeletedPresets ( $deletedPresets = [])

Sets deleted presets array

Аргументы
array$deletedPresets

См. определение в файле options.php строка 214

◆ setFilterRows()

setFilterRows ( $presetId,
$rows )

Sets filter preset rows

Аргументы
string$presetId
$rows

См. определение в файле options.php строка 960

◆ setFilterSettings()

setFilterSettings ( $presetId,
$settings,
$currentPreset = true,
$useRequest = true )
Аргументы
string$presetId
$settings
bool$currentPreset
bool$useRequest

См. определение в файле options.php строка 1065

◆ setFilterSettingsArray()

setFilterSettingsArray ( $settings = [])
Аргументы
array$settings

См. определение в файле options.php строка 1031

◆ setPresets()

setPresets ( $presets = [])

Sets filter presets

Аргументы
array$presets

См. определение в файле options.php строка 151

◆ setupDefaultFilter()

setupDefaultFilter ( array $fields,
array $rows )

Setup Default Filter Settings

Аргументы
array$fieldsDefault Filter Fields.
array$rowsDefault Filter Rows.

См. определение в файле options.php строка 1209

◆ setUsePinPreset()

setUsePinPreset ( $value = true)

Sets use_pin_preset values

Аргументы
boolean$value

См. определение в файле options.php строка 223

◆ trySetFilterFromRequest()

trySetFilterFromRequest ( $fields = [])
protected

См. определение в файле options.php строка 542

Поля

◆ $commonPresets

$commonPresets
protected

См. определение в файле options.php строка 22

◆ $commonPresetsId

$commonPresetsId
protected

См. определение в файле options.php строка 24

◆ $currentFilterPresetId

string $currentFilterPresetId = null
protected

См. определение в файле options.php строка 26

◆ $id

$id
protected

См. определение в файле options.php строка 20

◆ $options

$options
protected

См. определение в файле options.php строка 21

◆ $request

$request
protected

См. определение в файле options.php строка 25

◆ $useCommonPresets

$useCommonPresets
protected

См. определение в файле options.php строка 23

◆ DEFAULT_FILTER

const DEFAULT_FILTER = "default_filter"

См. определение в файле options.php строка 17

◆ TMP_FILTER

const TMP_FILTER = "tmp_filter"

См. определение в файле options.php строка 18


Объявления и описания членов классов находятся в файлах:
  • C:/bitrix/modules/main/lib/ui/filter/options.php
  • C:/bitrix/modules/socialnetwork/lib/Collab/Property/Options.php