mirror of
https://github.com/silverstripe/silverstripe-frameworktest
synced 2024-10-22 11:06:02 +02:00
18 lines
468 B
PHP
18 lines
468 B
PHP
<?php
|
|
|
|
namespace SilverStripe\FrameworkTest\Fields\NestedGridField;
|
|
|
|
use SilverStripe\Core\Extension;
|
|
use SilverStripe\Security\Group;
|
|
use Symbiote\GridFieldExtensions\GridFieldNestedForm;
|
|
|
|
class SecurityAdminExtension extends Extension
|
|
{
|
|
public function updateGridFieldConfig($config)
|
|
{
|
|
if ($this->owner->getModelClass() === Group::class) {
|
|
$config->addComponent(GridFieldNestedForm::create()->setRelationName('Members'));
|
|
}
|
|
}
|
|
}
|