Bitrix-D7 23.9
 
Загрузка...
Поиск...
Не найдено
fullprepaymentcheck.php
1<?php
2
3namespace Bitrix\Sale\Cashbox;
4
7
8Main\Localization\Loc::loadMessages(__FILE__);
9
15{
19 public static function getType()
20 {
21 return 'fullprepayment';
22 }
23
28 public static function getCalculatedSign()
29 {
30 return static::CALCULATED_SIGN_INCOME;
31 }
32
36 public static function getName()
37 {
38 return Main\Localization\Loc::getMessage('SALE_CASHBOX_FULLPREPAYMENT_NAME');
39 }
40
44 public static function getSupportedEntityType()
45 {
46 return static::SUPPORTED_ENTITY_TYPE_PAYMENT;
47 }
48
52 public static function getSupportedRelatedEntityType()
53 {
54 return static::SUPPORTED_ENTITY_TYPE_SHIPMENT;
55 }
56
68 protected function extractDataInternal()
69 {
70 $result = parent::extractDataInternal();
71
72 foreach ($result['PRODUCTS'] as $i => $item)
73 {
74 $result['PRODUCTS'][$i]['PAYMENT_OBJECT'] = static::PAYMENT_OBJECT_PAYMENT;
75 }
76
77 if (!empty($result['DELIVERY']) && \is_array($result['DELIVERY']))
78 {
79 foreach ($result['DELIVERY'] as $i => $item)
80 {
81 $result['DELIVERY'][$i]['PAYMENT_OBJECT'] = static::PAYMENT_OBJECT_PAYMENT;
82 }
83 }
84
85 return $result;
86 }
87
88 protected function needPrintMarkingCode($basketItem) : bool
89 {
90 return false;
91 }
92}