Documentation

DataProviderManager

DataProviderManager - singleton that stores provider hash. It collects methods for manipulation provider data - their initialization, value retrieval and etc.

Class methods

MethodDescription
getDataProviderValue(\Bitrix\DocumentGenerator\DataProvider $dataProvider, $placeholder)Passes provider value by name. In simplest case - calls provider getValue().
createDataProvider(array $fieldDescription, $value = null, \Bitrix\DocumentGenerator\DataProvider $parentDataProvider = null, $placeholder = null)Method creates new provider by its description and value. Here:
$fieldDescription - field description array
$value - this field value
$parentDataProvider - parent provider
$placeholder - name of parent provider name used to create this provider.
getArray(\Bitrix\DocumentGenerator\DataProvider $dataProvider)Converts provider into array. Convenient method for debugging or when placeholder chain is precisely known.
getList(array $params)Method returns list of providers. Filter can be passed by the module $params['filter']['MODULE'] = 'crm'
getDefaultTemplateFields($providerClassName, array $placeholders = [], array $mainProviderOptions = [], $isAddRootGroups = true)Method passes list of fields by default for provider.
$providerClassName - full name of provider class (instance will be created inside method)
$placeholders - array of field names to be returned
$mainProviderOptions - parameter $options for calling provider constructor
$isAddRootGroups - field group description adds first "Document"element.


© «Bitrix24», 2001-2022
Up