mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 12:05:37 +00:00
MINOR Added GridFieldTitle to Group->getCMSFields() to allow addition of new records (currently that button is hardcoded in the title component)
This commit is contained in:
parent
424da6abe1
commit
c4e04899b6
@ -62,7 +62,7 @@ class Group extends DataObject {
|
||||
Requirements::javascript(SAPPHIRE_DIR . '/javascript/PermissionCheckboxSetField.js');
|
||||
|
||||
$config = new GridFieldConfig_ManyManyEditor('FirstName', 20);
|
||||
$config->addComponents(new GridFieldExporter());
|
||||
$config->addComponents(new GridFieldExporter(), new GridFieldTitle());
|
||||
$config->getComponentByType('GridFieldRelationAdd')
|
||||
->setResultsFormat('$Title ($Email)')->setSearchFields(array('FirstName', 'Surname', 'Email'));
|
||||
$memberList = new GridField('Members','Members', $this->Members(), $config);
|
||||
|
Loading…
x
Reference in New Issue
Block a user