1C-Bitrix 25.700.0
Загрузка...
Поиск...
Не найдено
propertyvaluebase.php
См. документацию.
1<?php
2
3namespace Bitrix\Sale;
4
5use Bitrix\Sale\Internals\Entity;
6use Bitrix\Main;
7
13{
18 protected static function getOnSavedEventName(): string
19 {
20 return 'OnSalePropertyValueEntitySaved';
21 }
22
26 protected static function getPropertyClassName(): string
27 {
28 $registry = Registry::getInstance(static::getRegistryType());
29 return $registry->getPropertyClassName();
30 }
31
35 protected static function getEntityType(): string
36 {
37 return \Bitrix\Sale\Registry::ENTITY_ORDER;
38 }
39
40
45 public static function loadForOrder(OrderBase $order): array
46 {
47 return static::loadForEntity($order);
48 }
49
56 protected static function createPropertyValueObject(
57 array $property = null,
58 array $value = [],
59 array $relation = null
61 {
62 $registry = Registry::getInstance(static::getRegistryType());
63 $propertyValueClassName = $registry->getPropertyValueClassName();
64 return new $propertyValueClassName($property, $value, $relation);
65 }
66
71 protected static function extractPaySystemIdList(Entity $order)
72 {
73 return [$order->getField('PAY_SYSTEM_ID')];
74 }
75
80 protected static function extractDeliveryIdList(Entity $order)
81 {
82 return [(int)$order->getField('DELIVERY_ID')];
83 }
84
95 public static function loadOptions($propertyId)
96 {
97 $registry = Registry::getInstance(static::getRegistryType());
98
100 $propertyClassName = $registry->getPropertyClassName();
101 $property = $propertyClassName::getObjectById($propertyId);
102
103 if ($property)
104 {
105 return $property->getOptions();
106 }
107
108 return [];
109 }
110
123 public static function getMeaningfulValues($personTypeId, $request)
124 {
125 $registry = Registry::getInstance(static::getRegistryType());
126
128 $propertyClassName = $registry->getPropertyClassName();
129 return $propertyClassName::getMeaningfulValues($personTypeId, $request);
130 }
131
137 public static function getEntityEventName()
138 {
139 return 'SalePropertyValue';
140 }
141}
if(!Loader::includeModule('catalog')) if(!AccessController::getCurrent() ->check(ActionDictionary::ACTION_PRICE_EDIT)) if(!check_bitrix_sessid()) $request
Определения catalog_reindex.php:36
static getOnSavedEventName()
Определения propertyvaluebase.php:18
static getEntityType()
Определения propertyvaluebase.php:35
static loadForOrder(OrderBase $order)
Определения propertyvaluebase.php:45
static getEntityEventName()
Определения propertyvaluebase.php:137
static extractDeliveryIdList(Entity $order)
Определения propertyvaluebase.php:80
static extractPaySystemIdList(Entity $order)
Определения propertyvaluebase.php:71
static createPropertyValueObject(array $property=null, array $value=[], array $relation=null)
Определения propertyvaluebase.php:56
static getPropertyClassName()
Определения propertyvaluebase.php:26
static getInstance($type)
Определения registry.php:183
</td ></tr ></table ></td ></tr >< tr >< td class="bx-popup-label bx-width30"><?=GetMessage("PAGE_NEW_TAGS")?> array( $site)
Определения file_new.php:804
Определения ufield.php:9
$order
Определения payment.php:8