Server IP : 80.87.202.40 / Your IP : 216.73.216.169 Web Server : Apache System : Linux rospirotorg.ru 5.14.0-539.el9.x86_64 #1 SMP PREEMPT_DYNAMIC Thu Dec 5 22:26:13 UTC 2024 x86_64 User : bitrix ( 600) PHP Version : 8.2.27 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : ON Directory : /home/bitrix/ext_www/rospirotorg.ru/bitrix/modules/lpost.delivery/lib/Order/ |
Upload File : |
<? namespace Lpost\Delivery\Order; use Bitrix\Sale\Internals\Entity; use Bitrix\Sale\Order; use Bitrix\Sale\Result; use Bitrix\Sale\ResultWarning; /** * ����� ����������� �� ����� � ������������ ����� � ������ */ class OrderMarkerError { const LPOST_CODE_MARKER = 'LPOST_DELIVERY_ERROR_MARKER'; /** * ��������� ����� ����� * * @param Order $order * @param Entity $entity * @param string $message * @return void */ public static function create(Order $order, Entity $entity, string $message) { $result = new Result(); $result->addError(new ResultWarning($message, self::LPOST_CODE_MARKER)); \Bitrix\Sale\EntityMarker::addMarker($order, $entity, $result); } /** * �������� ����� * * @param Order $order * @return void */ public static function delete(Order $order) { \Bitrix\Sale\EntityMarker::deleteByOrderId($order->getId()); } }