You are here

public static function FooTableBreakpoint::loadAll in FooTable 8.2

Same name and namespace in other branches
  1. 8 src/Entity/FooTableBreakpoint.php \Drupal\footable\Entity\FooTableBreakpoint::loadAll()

Returns a list of FooTable breakpoints including the default FooTable breakpoint (All).

Return value

static[] An array of FooTable breakpoint objects indexed by their IDs.

Overrides FooTableBreakpointInterface::loadAll

1 call to FooTableBreakpoint::loadAll()
FooTable::buildOptionsForm in src/Plugin/views/style/FooTable.php
Render the given style.

File

src/Entity/FooTableBreakpoint.php, line 83

Class

FooTableBreakpoint
Defines the FooTable Breakpoint Config entity.

Namespace

Drupal\footable\Entity

Code

public static function loadAll() {
  $breakpoints = self::loadMultiple();

  // Add 'All' breakpoint.
  $values = [
    'label' => 'All',
    'name' => 'all',
    'breakpoint' => 'all',
  ];
  $breakpoints['all'] = new self($values, 'footable_breakpoint');
  uasort($breakpoints, [
    __CLASS__,
    'sort',
  ]);
  return $breakpoints;
}