Documentation

Simple extends Base
in package

Class constructs grids

Table of Contents

$listDescription  : string
List description
$listTitle  : string
List title
$noItemsTemplateName  : string
Name of the template for the empty records list
$fields  : array<string|int, mixed>
Fields
$listBuilderAdapter  : ListBuilderAdapter
Service logic adapter
$noItemsView  : string
No items block name
$recordTransformer  : array<string|int, mixed>
List item transformation callback
__construct()  : mixed
Constructor
getFields()  : array<string|int, mixed>
Method returns fields
listingForm()  : string
Method compiles simple_listing form
setNoItemsView()  : void
Method sets field $noItemsView
setRecordTransformer()  : void
Setting record transformer
getListBuilderAdapter()  : ListBuilderAdapter
Method returns list builder adapter
getNoItemsContent()  : string
Method returns content for the case when no items were found
transformRecord()  : object
Method transforms database record
listingHeaderCells()  : string
Method compiles header cells
listingItemsCells()  : string
Method compiles listing items cells
simpleListingHeader()  : string
Method compiles listing header
simpleListingItems()  : string
Method compiles listing items

Properties

$listDescription

List description

public string $listDescription = 'Выберите необходимое действие'

$listTitle

List title

public string $listTitle = 'Список записей'

$noItemsTemplateName

Name of the template for the empty records list

protected string $noItemsTemplateName = 'listing-no-items'

$fields

Fields

private array<string|int, mixed> $fields = []

$noItemsView

No items block name

private string $noItemsView = ''

$recordTransformer

List item transformation callback

private array<string|int, mixed> $recordTransformer = []

Methods

__construct()

Constructor

public __construct(array<string|int, mixed> $fields, ListBuilderAdapter $listBuilderAdapter) : mixed
Parameters
$fields : array<string|int, mixed>

List of fields

$listBuilderAdapter : ListBuilderAdapter

Adapter for the data source

Return values
mixed

getFields()

Method returns fields

public getFields() : array<string|int, mixed>
Return values
array<string|int, mixed>

fields

listingForm()

Method compiles simple_listing form

public listingForm() : string
Return values
string

Compiled simple listing form

setNoItemsView()

Method sets field $noItemsView

public setNoItemsView(string $noItemsView) : void
Parameters
$noItemsView : string
Return values
void

setRecordTransformer()

Setting record transformer

public setRecordTransformer(mixed $recordTransformer) : void
Parameters
$recordTransformer : mixed

callable record transformer

Tags
codeCoverageIgnore
Return values
void

getNoItemsContent()

Method returns content for the case when no items were found

protected getNoItemsContent() : string
Return values
string

content for the case when no items were found

transformRecord()

Method transforms database record

protected transformRecord(object $record) : object
Parameters
$record : object

Transforming record

Return values
object

Transformed record

listingHeaderCells()

Method compiles header cells

private listingHeaderCells() : string
Return values
string

Compiled header

listingItemsCells()

Method compiles listing items cells

private listingItemsCells() : string
Return values
string

Compiled row

simpleListingHeader()

Method compiles listing header

private simpleListingHeader() : string
Return values
string

Compiled header

simpleListingItems()

Method compiles listing items

private simpleListingItems(array<string|int, mixed> $records) : string
Parameters
$records : array<string|int, mixed>

List of records

Return values
string

Compiled simple list

Search results

    Яндекс.Метрика