From 81939b2b4af89800d67c8a3495d2bfa705cde37c Mon Sep 17 00:00:00 2001 From: Steve Boyd Date: Tue, 14 Jan 2025 16:18:23 +1300 Subject: [PATCH] API Rename FormField Value to getFormattedValue --- src/Forms/LocaleToggleColumn.php | 2 +- tests/php/Model/LocaleTest.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Forms/LocaleToggleColumn.php b/src/Forms/LocaleToggleColumn.php index 4d950ed2..41b6a83c 100644 --- a/src/Forms/LocaleToggleColumn.php +++ b/src/Forms/LocaleToggleColumn.php @@ -93,7 +93,7 @@ public function getColumnMetadata($gridField, $columnName) public function handleSave(GridField $gridField, DataObjectInterface $record) { - $value = $gridField->Value(); + $value = $gridField->getValue(); // Keys for this value will be list of locales to enable $enabledLocales = isset($value[LocaleToggleColumn::COLUMN_NAME]) diff --git a/tests/php/Model/LocaleTest.php b/tests/php/Model/LocaleTest.php index 4bd22a5b..3e24db71 100644 --- a/tests/php/Model/LocaleTest.php +++ b/tests/php/Model/LocaleTest.php @@ -212,7 +212,7 @@ public function testGlobalDefaultCheckedOnFirstLocale() /** @var CheckboxField $checkbox */ $checkbox = $fields->fieldByName('Root.Main.IsGlobalDefault'); - $this->assertTrue((bool)$checkbox->Value()); + $this->assertTrue((bool)$checkbox->getValue()); } public function testGetLocaleSuffix()