ListWidget implements WidgetInterface, RequestAwareWidgetInterface
Concrete List Widget implementation
The widget will show a simple list with items provided by a data provider. You can add a button to the widget by defining a button provider.
There are no options available for this widget
Tags
Table of Contents
Interfaces
- WidgetInterface
- The WidgetInterface is the base interface for all kind of widgets.
- RequestAwareWidgetInterface
- Interface for widgets that need the ServerRequestInterface Request.
Properties
- $view : StandaloneView|null
Methods
- __construct() : mixed
- getOptions() : array<string|int, mixed>
- This method returns the options of the widget as set in the registration.
- renderWidgetContent() : string
- This method returns the content of a widget. The returned markup will be delivered by an AJAX call and will not be escaped.
- setRequest() : void
- getItems() : array<string|int, mixed>
Properties
$view read-only
protected
StandaloneView|null
$view
= null
Methods
__construct()
public
__construct(WidgetConfigurationInterface $configuration, ListDataProviderInterface $dataProvider, BackendViewFactory $backendViewFactory[, StandaloneView|null $view = null ][, ButtonProviderInterface|null $buttonProvider = null ][, array<string|int, mixed> $options = [] ]) : mixed
Parameters
- $configuration : WidgetConfigurationInterface
- $dataProvider : ListDataProviderInterface
- $backendViewFactory : BackendViewFactory
- $view : StandaloneView|null = null
- $buttonProvider : ButtonProviderInterface|null = null
- $options : array<string|int, mixed> = []
getOptions()
This method returns the options of the widget as set in the registration.
public
getOptions() : array<string|int, mixed>
Return values
array<string|int, mixed>renderWidgetContent()
This method returns the content of a widget. The returned markup will be delivered by an AJAX call and will not be escaped.
public
renderWidgetContent() : string
Be aware of XSS and ensure that the content is well encoded.
Return values
stringsetRequest()
public
setRequest(ServerRequestInterface $request) : void
Parameters
- $request : ServerRequestInterface
getItems()
protected
getItems() : array<string|int, mixed>