public function toStorageFieldDefinition(FieldDefinition $fieldDef, StorageFieldDefinition $storageDef) { // Selection method, 0 = browse, 1 = dropdown $storageDef->dataInt1 = (int) $fieldDef->fieldTypeConstraints->fieldSettings['selectionMethod']; // Selection root, location ID $storageDef->dataInt2 = (int) $fieldDef->fieldTypeConstraints->fieldSettings['selectionRoot']; }