Bitrix-D7 23.9
 
Загрузка...
Поиск...
Не найдено
price.php
1<?php
2
4
11
13{
19 protected static function extractParams(Entity $entity)
20 {
22 $collection = null;
23
24 if ($entity instanceof Payment)
25 $collection = $entity->getCollection();
26 elseif ($entity instanceof Shipment)
27 $collection = $entity->getCollection();
28 elseif ($entity instanceof Order)
29 {
30 return array('PRICE_PAYMENT' => $entity->getPrice());
31 }
32
33 if ($collection)
34 {
36 $order = $collection->getOrder();
37
38 return array('PRICE_PAYMENT' => $order->getPrice());
39 }
40
41 return array('PRICE_PAYMENT' => null);
42 }
43}