|
static | getLinkField () |
static | getTargetEntityName () |
static | getTypeField () |
static | getLocationLinkField () |
static | getTargetEntityPrimaryField () |
static | getUseGroups () |
static | getUseLinkTracking () |
static | getConnectType () |
static | getUseCodes () |
static | add (array $data) |
static | update ($primary, array $data) |
static | delete ($primary) |
static | onAfterModifiy () |
static | updateMultipleForOwner ($entityPrimary, $links=array(), $behaviour=array('REMOVE_ABSENT'=> true)) |
static | deleteAllForOwner ($entityPrimary, $behaviour=array('BATCH_MODE'=> false)) |
static | deleteAll () |
static | resetMultipleForOwner ($entityPrimary, $links=array()) |
static | getConnectedLocationsQuery ($entityPrimary, $parameters=array(), $behaviour=array('GET_LINKED_THROUGH_GROUPS'=> false)) |
static | getConnectedLocationsSql ($entityPrimary, $parameters=array(), $behaviour=array('GET_LINKED_THROUGH_GROUPS'=> false)) |
static | getConnectedLocations ($entityPrimary, $parameters=array(), $behaviour=array('GET_LINKED_THROUGH_GROUPS'=> false)) |
static | getConnectedGroups ($entityPrimary, $parameters=array()) |
static | getConnectedEntites ($locationPrimary, $parameters=array()) |
static | getConnectedEntitesByCode ($locationPrimary, $parameters=array()) |
static | getConnectedEntitiesQuery ($locationPrimary, $linkType='id', $parameters=array()) |
static | getLinkStatusForMultipleNodes ($nodeInfo, $entityPrimary, $connectors=false) |
static | checkConnectionExists ($entityPrimary, $locationPrimary, array $behaviour=array('LOCATION_LINK_TYPE'=> 'ID')) |
static | checkLinkUsageAny ($entityPrimary) |
static | checkLinkUsage ($entityPrimary, $linkType=self::DB_LOCATION_FLAG) |
static | unionize ($sqls) |
static | normalizeLocationList ($denormalizedList=array()) |
См. определение в файле connector.php строка 20
◆ add()
Adds a new connection between location and entity
- Аргументы
-
mixed[] | $data | data to add (See getMap() of a certain implementation for $data key details) |
- Возвращает
- Bitrix\Main\Entity\AddResult
См. определение в файле connector.php строка 140
◆ checkConnectionExists()
checkConnectionExists |
( |
| $entityPrimary, |
|
|
| $locationPrimary, |
|
|
array | $behaviour = array('LOCATION_LINK_TYPE' => 'ID') ) |
|
static |
Check if location is connected with entity
- Аргументы
-
$entityPrimary | mixed Entity being checked |
$locationPrimary | mixed Location being checked. Could be a value of ID or CODE depending on what connection type is selected (see below) |
$behaviour | mixed[] A set of flags that modify function behaviour LOCATION_LINK_TYPE string One of: ID, CODE, AUTO. If ID, than match by ID is used (default, for compatibility), if CODE than match by CODE. In case of AUTO the target field value depends on entity connect type. |
- Возвращает
- boolean
См. определение в файле connector.php строка 1035
◆ checkLinkUsage()
checkLinkUsage |
( |
| $entityPrimary, |
|
|
| $linkType = self::DB_LOCATION_FLAG ) |
|
static |
Check if there is a link between entity and locations, optionally of a certain type (default: locations)
- Аргументы
-
mixed | $entityPrimary | primary key for an entity |
string | $linkType | link type (G or L (default)) |
- Исключения
-
- Возвращает
- boolean
См. определение в файле connector.php строка 1122
◆ checkLinkUsageAny()
checkLinkUsageAny |
( |
| $entityPrimary | ) |
|
|
static |
◆ delete()
Removes a connection between location and entity
- Аргументы
-
mixed | $primary | relation primary key value |
- Возвращает
- Bitrix\Main\Entity\DeleteResult
См. определение в файле connector.php строка 187
◆ deleteAll()
◆ deleteAllForOwner()
deleteAllForOwner |
( |
| $entityPrimary, |
|
|
| $behaviour = array('BATCH_MODE' => false) ) |
|
static |
◆ getConnectedEntites()
getConnectedEntites |
( |
| $locationPrimary, |
|
|
| $parameters = array() ) |
|
static |
◆ getConnectedEntitesByCode()
getConnectedEntitesByCode |
( |
| $locationPrimary, |
|
|
| $parameters = array() ) |
|
static |
◆ getConnectedEntitiesByCondition()
getConnectedEntitiesByCondition |
( |
| $locationPrimary, |
|
|
| $linkType = 'id', |
|
|
| $parameters = array() ) |
|
staticprotected |
◆ getConnectedEntitiesQuery()
getConnectedEntitiesQuery |
( |
| $locationPrimary, |
|
|
| $linkType = 'id', |
|
|
| $parameters = array() ) |
|
static |
◆ getConnectedGroups()
getConnectedGroups |
( |
| $entityPrimary, |
|
|
| $parameters = array() ) |
|
static |
Returns a set of location groups that connected with a given entity.
- Аргументы
-
mixed | $entityPrimary | primary key for an entity |
mixed[] | $parameters | for ORM getList() |
- Исключения
-
ArgumentNullException | |
NotImplementedException | |
- Возвращает
- \Bitrix\Main\DB\Result list of locations
См. определение в файле connector.php строка 695
◆ getConnectedLocations()
getConnectedLocations |
( |
| $entityPrimary, |
|
|
| $parameters = array(), |
|
|
| $behaviour = array('GET_LINKED_THROUGH_GROUPS' => false) ) |
|
static |
◆ getConnectedLocationsInfo()
getConnectedLocationsInfo |
( |
| $entityPrimary | ) |
|
|
staticprotected |
◆ getConnectedLocationsQuery()
getConnectedLocationsQuery |
( |
| $entityPrimary, |
|
|
| $parameters = array(), |
|
|
| $behaviour = array('GET_LINKED_THROUGH_GROUPS' => false) ) |
|
static |
Returns a set of locations that connected with a given entity, directly and, optionally, through groups.
- Аргументы
-
mixed | $entityPrimary | primary key for an entity |
mixed[] | $parameters | filter and select parameters in ORM getlist() style, functionality is enought for usage, but limited. See limitations in code comments. |
string[] | $behaviour | a set of behaviour options:
-
GET_LINKED_THROUGH_GROUPS boolean (default true) - if set to true, locations will be searched also throurgh groups (if entity connector supports groups)
|
- Исключения
-
ArgumentNullException | |
NotImplementedException | |
- Возвращает
- String an SQL-query string that, being called, returns a list of locations
См. определение в файле connector.php строка 467
◆ getConnectedLocationsSql()
getConnectedLocationsSql |
( |
| $entityPrimary, |
|
|
| $parameters = array(), |
|
|
| $behaviour = array('GET_LINKED_THROUGH_GROUPS' => false) ) |
|
static |
More preferable alias for getConnectedLocationsQuery()
См. определение в файле connector.php строка 665
◆ getConnectType()
Return the connection type for the current entity. Return value that is equal to self::LINK_ID stands for ID, otherwise - for CODE link type
- Возвращает
- integer
См. определение в файле connector.php строка 108
◆ getLinkedLocations()
getLinkedLocations |
( |
| $entityPrimary | ) |
|
|
staticprotected |
◆ getLinkField()
◆ getLinkStatusForMultipleNodes()
getLinkStatusForMultipleNodes |
( |
| $nodeInfo, |
|
|
| $entityPrimary, |
|
|
| $connectors = false ) |
|
static |
Functions for massive check for link type
См. определение в файле connector.php строка 969
◆ getLocationLinkField()
◆ getTargetEntityName()
◆ getTargetEntityPrimaryField()
getTargetEntityPrimaryField |
( |
| ) |
|
|
static |
Returns a name of the primary field of the "target" entity. By default 'ID' is used for the most. See target entity class for sure.
- Возвращает
- string
Переопределяется в SiteLocationTable.
См. определение в файле connector.php строка 76
◆ getTypeField()
Returns a name of type filed. By default 'LOCATION_TYPE' is used for the most of. Does not make any sense if getUseGroups() returns false
- Возвращает
- string
Переопределяется в GroupLocationTable.
См. определение в файле connector.php строка 56
◆ getUseCodes()
Just a shortcut to link type identification
- Возвращает
- boolean
См. определение в файле connector.php строка 124
◆ getUseGroups()
Show whether or not entity use linking through groups. E.g. delivery would return true, but location groups (which can be treated as entity too) - always return false (groups cannot be connected with groups)
- Возвращает
- boolean
Переопределяется в GroupLocationTable.
См. определение в файле connector.php строка 87
◆ getUseLinkTracking()
Show whether or not entity use link tracking. Link tracking allows keeping information about link existence in option strings. So, this is some kind of cacheing mechanism. It can be usefull, but may exceed option string length when there are lots of entity records exist.
- Возвращает
- boolean
Переопределяется в SiteLocationTable.
См. определение в файле connector.php строка 98
◆ normalizeLocationList()
normalizeLocationList |
( |
| $denormalizedList = array() | ) |
|
|
static |
◆ onAfterModifiy()
◆ queryPage()
queryPage |
( |
| $sql, |
|
|
| $limit = 0, |
|
|
| $offset = 0 ) |
|
staticprotected |
A special paginator for UNION-like queries
- Аргументы
-
string | $sql | SQL select query to execute, wrapped in union |
integer | $limit | record limit to fetch (default: 0) |
integer | $offset | offset to start fetching records from (default: 0) |
- Возвращает
- Bitrix\Main\DB\Result
См. определение в файле connector.php строка 1300
◆ resetMultipleForOwner()
resetMultipleForOwner |
( |
| $entityPrimary, |
|
|
| $links = array() ) |
|
static |
Removes all links and creates new ones
См. определение в файле connector.php строка 332
◆ unionize()
Wraps a set of sqls to a union
- Аргументы
-
string[] | $sqls | a set of SQL select queries to wrap |
- Возвращает
- string
См. определение в файле connector.php строка 1355
◆ update()
update |
( |
| $primary, |
|
|
array | $data ) |
|
static |
Updates a connection between location and entity
- Аргументы
-
mixed | $primary | relation primary key value |
mixed[] | $data | data to update with (See getMap() of a certain implementation for $data key details) |
- Возвращает
- Bitrix\Main\Entity\UpdateResult
См. определение в файле connector.php строка 160
◆ updateMultipleForOwner()
updateMultipleForOwner |
( |
| $entityPrimary, |
|
|
| $links = array(), |
|
|
| $behaviour = array('REMOVE_ABSENT' => true) ) |
|
static |
Establishes several connections between entity and locations. Could be used to add and delete selected relations.
- Аргументы
-
mixed | $entityPrimary | primary key for an entity |
integer[][] | string[][] | $links | array of locations and groups to link an entity with Argument format:
array(
'L' => array(), // an array of IDs or CODEs of locations
'G' => array() // an array of IDs or CODEs of location groups
)
|
- Исключения
-
Main\ArgumentNullException
- Возвращает
- boolean
См. определение в файле connector.php строка 222
◆ DB_GROUP_FLAG
const DB_GROUP_FLAG = 'G' |
◆ DB_LOCATION_FLAG
const DB_LOCATION_FLAG = 'L' |
◆ LINK_CODE
◆ LINK_ID
◆ LSTAT_ABOVE_CONNECTOR
const LSTAT_ABOVE_CONNECTOR = 0x03 |
◆ LSTAT_BELOW_CONNECTOR
const LSTAT_BELOW_CONNECTOR = 0x04 |
◆ LSTAT_IN_NOT_CONNECTED_BRANCH
const LSTAT_IN_NOT_CONNECTED_BRANCH = 0x01 |
◆ LSTAT_IS_CONNECTOR
const LSTAT_IS_CONNECTOR = 0x02 |
Объявления и описания членов класса находятся в файле: