mirror of
https://github.com/symbiote/silverstripe-gridfieldextensions.git
synced 2024-10-22 17:05:39 +02:00
Added initial user documentation for Nested GridFields.
This commit is contained in:
parent
19a7cffa88
commit
bcc4ea14bb
@ -152,3 +152,17 @@ $paginator->setItemsPerPage(500);
|
|||||||
|
|
||||||
The first shown record will be maintained across page size changes, and the number of pages and current page will be
|
The first shown record will be maintained across page size changes, and the number of pages and current page will be
|
||||||
recalculated on each request, based on the current first shown record and page size.
|
recalculated on each request, based on the current first shown record and page size.
|
||||||
|
|
||||||
|
Nested GridFields
|
||||||
|
-----------------
|
||||||
|
|
||||||
|
The `GridFieldNestedForm` component allows you to nest GridFields in the UI. It can be used with `DataObject` subclasses
|
||||||
|
with the `Hierarchy` extension, or by specifying the relation used for nesting.
|
||||||
|
|
||||||
|
```php
|
||||||
|
// Basic usage, defaults to the Children-method for Hierarchy objects.
|
||||||
|
$grid->getConfig()->addComponent(GridFieldNestedForm::create());
|
||||||
|
|
||||||
|
// Usage with custom relation
|
||||||
|
$grid->getConfig()->addComponent(GridFieldNestedForm::create()->setRelationName('MyRelation'));
|
||||||
|
```
|
||||||
|
Loading…
Reference in New Issue
Block a user