1C-Bitrix 25.700.0
Загрузка...
Поиск...
Не найдено
restrictioncurrencytrait.php
См. документацию.
1<?php
2
3namespace Bitrix\Sale\Services\PaySystem\Restrictions;
4
5use Bitrix\Sale\Services\Base\RestrictionInfo;
6use Bitrix\Sale\Services\Base\RestrictionInfoCollection;
7
9{
10 abstract public function getCurrencyList();
11
12 protected function getRestrictionCurrency(RestrictionInfoCollection $collection): void
13 {
14 $currencyList = $this->getCurrencyList();
15 if (!empty($currencyList) && is_array($currencyList))
16 {
17 $currencyRestrictionContainer = new RestrictionInfo(
18 'Currency',
19 [
20 'CURRENCY' => $currencyList,
21 ]
22 );
23 $collection->add($currencyRestrictionContainer);
24 }
25 }
26}
add(RestrictionInfo $restrictionInfo)
Определения restrictioninfocollection.php:19
getRestrictionCurrency(RestrictionInfoCollection $collection)
Определения restrictioncurrencytrait.php:12