Skip to content

Commit

Permalink
FIX Remove automatically scaffolded GridField for Site Tree Content R…
Browse files Browse the repository at this point in the history
…eview in Member fields
  • Loading branch information
robbieaverill committed Mar 22, 2018
1 parent f5052ed commit dd7d1a7
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions src/Extensions/ContentReviewOwner.php
Expand Up @@ -3,11 +3,9 @@
namespace SilverStripe\ContentReview\Extensions;

use SilverStripe\CMS\Model\SiteTree;
use SilverStripe\Forms\FieldList;
use SilverStripe\ORM\DataExtension;

/**
* Description of GroupContentReview.
*/
class ContentReviewOwner extends DataExtension
{
/**
Expand All @@ -16,4 +14,10 @@ class ContentReviewOwner extends DataExtension
private static $many_many = [
"SiteTreeContentReview" => SiteTree::class,
];

public function updateCMSFields(FieldList $fields)
{
// Remove automatically scaffolded GridField in Member CMS fields
$fields->removeByName('SiteTreeContentReview');
}
}

0 comments on commit dd7d1a7

Please sign in to comment.