1C-Bitrix 25.700.0
Загрузка...
Поиск...
Не найдено
formatrepository.php
См. документацию.
1<?php
2
3namespace Bitrix\Location\Repository;
4
5use Bitrix\Location\Entity;
6use Bitrix\Location\Repository\Format\DataCollection;
7use Bitrix\Location\Entity\Format\Converter\ArrayConverter;
8
14{
16 protected $dataCollection;
17
22 public function __construct(array $params = [])
23 {
24 if(isset($params['dataCollection']) && is_subclass_of($params['dataCollection'], DataCollection::class))
25 {
26 $this->dataCollection = $params['dataCollection'];
27 }
28 else
29 {
30 $this->dataCollection = DataCollection::class;
31 }
32 }
33
38 public function findAll(string $language): array
39 {
40 $result = [];
41
42 foreach ($this->dataCollection::getAll($language) as $data)
43 {
44 $result[] = ArrayConverter::convertFromArray($data, $language);
45 }
46
47 return $result;
48 }
49
55 public function findByCode(string $code, string $languageId):? Entity\Format
56 {
57 $data = $this->dataCollection::getByCode($code, $languageId);
58 return is_array($data) ? ArrayConverter::convertFromArray($data, $languageId) : null;
59 }
60}
__construct(array $params=[])
Определения formatrepository.php:22
findByCode(string $code, string $languageId)
Определения formatrepository.php:55
$data['IS_AVAILABLE']
Определения .description.php:13
</td ></tr ></table ></td ></tr >< tr >< td class="bx-popup-label bx-width30"><?=GetMessage("PAGE_NEW_TAGS")?> array( $site)
Определения file_new.php:804
$result
Определения get_property_values.php:14
if(!is_null($config))($config as $configItem)(! $configItem->isVisible()) $code
Определения options.php:195
Определения ufield.php:9
if($inWords) echo htmlspecialcharsbx(Number2Word_Rus(roundEx($totalVatSum $params['CURRENCY']
Определения template.php:799