You are here

public function BookingListBuilder::buildHeader in Booking and Availability Management Tools for Drupal 8

Builds the header row for the entity listing.

Return value

array A render array structure of header strings.

Overrides EntityListBuilder::buildHeader

See also

\Drupal\Core\Entity\EntityListBuilder::render()

File

modules/bat_booking/src/BookingListBuilder.php, line 49
Contains \Drupal\bat_booking\BookingListBuilder.

Class

BookingListBuilder
Defines a class to build a listing of Unit entities.

Namespace

Drupal\bat_booking

Code

public function buildHeader() {
  $header = [
    'id' => [
      'data' => $this
        ->t('Booking ID'),
      'field' => 'id',
      'specifier' => 'id',
      'class' => [
        RESPONSIVE_PRIORITY_LOW,
      ],
    ],
    'name' => [
      'data' => $this
        ->t('Name'),
      'field' => 'name',
      'specifier' => 'name',
      'class' => [
        RESPONSIVE_PRIORITY_LOW,
      ],
    ],
    'type' => [
      'data' => $this
        ->t('Type'),
      'field' => 'type',
      'specifier' => 'type',
      'class' => [
        RESPONSIVE_PRIORITY_LOW,
      ],
    ],
    'status' => [
      'data' => $this
        ->t('Status'),
      'field' => 'status',
      'specifier' => 'status',
      'class' => [
        RESPONSIVE_PRIORITY_LOW,
      ],
    ],
  ];
  return $header + parent::buildHeader();
}