diff --git a/forms/TreeDropdownField.php b/forms/TreeDropdownField.php index eb53dbc0e..ff78b27fe 100755 --- a/forms/TreeDropdownField.php +++ b/forms/TreeDropdownField.php @@ -124,8 +124,9 @@ HTML; function performReadonlyTransformation() { $fieldName = $this->labelField; + $value = ($this->getByKey($this->value)) ? $this->getByKey($this->value)->$fieldName : ''; $source = array( - $this->value => $this->getByKey($this->value)->$fieldName + $this->value => $value ); $field = new LookupField($this->name, $this->title, $source); $field->setValue($this->value);