SchemaTrueFalseBase.php in Schema.org Metatag 7
File
src/SchemaTrueFalseBase.php
View source
<?php
class SchemaTrueFalseBase extends SchemaNameBase {
public function getForm(array $options = []) {
$form = parent::getForm($options);
$form['value']['#type'] = 'select';
$form['value']['#empty_option'] = $this
->t('- None -');
$form['value']['#empty_value'] = '';
$form['value']['#options'] = [
'False' => $this
->t('False'),
'True' => $this
->t('True'),
];
return $form;
}
public static function testValue() {
return 'True';
}
}