1C-Bitrix 25.700.0
Загрузка...
Поиск...
Не найдено
tabletgrid.php
См. документацию.
1<?php
2
3namespace Bitrix\Main\Grid;
4
5use Bitrix\Main\Grid\Column\Columns;
6use Bitrix\Main\Grid\Column\DataProvider\TabletColumnsProvider;
7use Bitrix\Main\ORM\Data\DataManager;
8use Bitrix\Main\ORM\Entity;
9
10abstract class TabletGrid extends Grid
11{
12 abstract protected function getTabletClass(): string;
13
14 final protected function getDataManager(): DataManager
15 {
16 $ref = new \ReflectionClass($this->getTabletClass());
17
18 return $ref->newInstance();
19 }
20
21 final protected function getEntity(): Entity
22 {
23 return $this->getDataManager()->getEntity();
24 }
25
26 protected function createColumns(): Columns
27 {
28 return new Columns(
29 new TabletColumnsProvider($this->getEntity()),
30 );
31 }
32}
Определения ufield.php:9