GeofieldField.php in Geocoder 8.3
File
modules/geocoder_geofield/src/Plugin/Geocoder/Field/GeofieldField.php
View source
<?php
namespace Drupal\geocoder_geofield\Plugin\Geocoder\Field;
use Drupal\Core\Field\FieldConfigInterface;
use Drupal\Core\Form\FormStateInterface;
use Drupal\geocoder_field\Plugin\Geocoder\Field\DefaultField;
class GeofieldField extends DefaultField {
public function getSettingsForm(FieldConfigInterface $field, array $form, FormStateInterface &$form_state) {
$element = parent::getSettingsForm($field, $form, $form_state);
$element['method']['#options'] = [
'none' => $this
->t('No geocoding'),
'geocode' => $this
->t('<b>Geocode</b> from an existing field'),
];
$element['dumper'] = [
'#type' => 'value',
'#value' => 'wkt',
];
return $element;
}
}