См. определение в файле restriction.php строка 16
◆ check()
static check |
( |
| $params, |
|
|
array | $restrictionParams, |
|
|
| $serviceId = 0 ) |
|
static |
Checking the service parameters for compliance with the restriction.
To check of the constraint itself, use method self::validateRestriction
- Аргументы
-
mixed | $params | Params to check. |
array | $restrictionParams | Restriction params. |
int | $serviceId | Service identifier. |
- Возвращает
- bool
- Исключения
-
Переопределяется в ConcreteProductRestriction, ProductCategoryRestriction, UserGroupRestriction, Company, PaySystem, TradeBindingRestriction, Currency, Delivery, EntityType, Location, PaySystem, Currency, Delivery, PersonType, Price и SiteRestriction.
См. определение в файле restriction.php строка 69
◆ checkByEntity()
static checkByEntity |
( |
Entity | $entity, |
|
|
array | $restrictionParams, |
|
|
| $mode, |
|
|
| $serviceId = 0 ) |
|
static |
Checking the service parameters for compliance with the restriction by entity.
- Аргументы
-
Entity | $entity | |
array | $restrictionParams | |
int | $mode | |
int | $serviceId | |
- Возвращает
- int
- Исключения
-
См. определение в файле restriction.php строка 84
◆ delete()
static delete |
( |
| $restrictionId, |
|
|
| $entityId = 0 ) |
|
static |
◆ extractParams()
static extractParams |
( |
Entity | $entity | ) |
|
|
staticprotected |
◆ getClassDescription()
static getClassDescription |
( |
| ) |
|
|
static |
- Возвращает
- string
- Исключения
-
Переопределяется в Company, PaySystem, ByConcreteProduct, ByProductCategory, SiteRestriction, TradeBindingRestriction, UserGroupRestriction, Currency, Delivery, EntityType, Location, PaySystem, ConcreteProduct, Currency, Delivery, PersonType, Price и ProductCategory.
См. определение в файле restriction.php строка 39
◆ getClassTitle()
- Возвращает
- string
- Исключения
-
Переопределяется в Company, PaySystem, ConcreteProductRestriction, ProductCategoryRestriction, SiteRestriction, TradeBindingRestriction, UserGroupRestriction, Currency, Delivery, EntityType, Location, PaySystem, Currency, Delivery, PersonType и Price.
См. определение в файле restriction.php строка 30
◆ getCode()
Get a restriction code that is comparable to the service handler restriction code.
Bitrix restrictions will return name of restriction class. Vendor restrictions must return full classname with namespace.
Example 1: for bitrix currency restriction class **Bitrix\Currency** it will return 'currency'
Example 2: for vendor currency restriction class **Vendor\Currency** it will return 'Vendor\Currency'
- Возвращает
- string
См. определение в файле restriction.php строка 214
◆ getOnApplyErrorMessage()
static getOnApplyErrorMessage |
( |
| ) |
|
|
static |
◆ getParamsStructure()
static getParamsStructure |
( |
| $entityId = 0 | ) |
|
|
static |
Returns params structure to show it to user
- Возвращает
- array
Переопределяется в Company, PaySystem, ConcreteProductRestriction, ProductCategoryRestriction, SiteRestriction, TradeBindingRestriction, UserGroupRestriction, Currency, Delivery, EntityType, Location, PaySystem, Delivery, PersonType и Price.
См. определение в файле restriction.php строка 124
◆ getSeverity()
static getSeverity |
( |
| $mode | ) |
|
|
static |
◆ isAvailable()
◆ isMyCode()
static isMyCode |
( |
string | $code | ) |
|
|
static |
◆ prepareData()
static prepareData |
( |
array | $servicesIds | ) |
|
|
static |
◆ prepareParamsValues()
static prepareParamsValues |
( |
array | $paramsValues, |
|
|
| $entityId = 0 ) |
|
static |
◆ save()
static save |
( |
array | $fields, |
|
|
| $restrictionId = 0 ) |
|
static |
◆ validateRestriction()
static validateRestriction |
( |
| $fields | ) |
|
|
static |
Checking the restriction for compliance with business rules.
For example, for the restriction "currency" in this method, you can compare which currencies the payment system works with which the restriction is linked.
- Аргументы
-
array | $fields | restriction fields |
- Возвращает
- Result
См. определение в файле restriction.php строка 105
◆ $easeSort