Skip to content

Commit

Permalink
ENH Allow the localisation manager to be filtered using BasicSearchCo…
Browse files Browse the repository at this point in the history
…ntext (#922)

ENH: Localisation manager filter.
  • Loading branch information
mfendeksilverstripe authored Jan 29, 2025
1 parent 7a04530 commit e883a2f
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
2 changes: 0 additions & 2 deletions src/Extension/Traits/FluentObjectTrait.php
Original file line number Diff line number Diff line change
Expand Up @@ -107,8 +107,6 @@ protected function updateFluentCMSFields(FieldList $fields)

// Generate gridfield for handling localisations
$config = GridFieldConfig_Base::create();
// Remove filters as the displayed data is in ArrayList format
$config->removeComponentsByType(GridFieldFilterHeader::class);

$columns = $config->getComponentByType(GridFieldDataColumns::class);
$summaryColumns = [
Expand Down
5 changes: 4 additions & 1 deletion tests/php/Extension/FluentFilteredExtensionTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,10 @@ public function testUpdateCMSFields()
LocaleToggleColumn::class,
$config->getComponentByType(LocaleToggleColumn::class)
);
$this->assertNull($config->getComponentByType(GridFieldFilterHeader::class));
$this->assertInstanceOf(
GridFieldFilterHeader::class,
$config->getComponentByType(GridFieldFilterHeader::class)
);
});
}

Expand Down

0 comments on commit e883a2f

Please sign in to comment.