mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 14:05:37 +02:00
Merge pull request #9019 from rafaeldsousa/pull/include-cancreate-check-gridfield-rightgroupfield
Including canCreate in if statement so that button gets removed if us…
This commit is contained in:
commit
179a982f45
@ -323,7 +323,7 @@ class GridFieldDetailForm_ItemRequest extends RequestHandler
|
||||
|
||||
$rightGroup->push($previousAndNextGroup);
|
||||
|
||||
if ($component && $component->getShowAdd()) {
|
||||
if ($component && $component->getShowAdd() && $this->record->canCreate()) {
|
||||
$rightGroup->push(
|
||||
LiteralField::create(
|
||||
'new-record',
|
||||
|
Loading…
Reference in New Issue
Block a user