/** * @param Field|FieldBoolean $entity * @param array $options * * @return array */ public function getTemplateOptions($entity, array $options) { return ['value' => $entity->getValue() === $options['true_value'] ? $options['true_value'] : $options['false_value']]; }
/** * @param Field|FieldNumber $entity * @param array $options * * @return array */ public function getTemplateOptions($entity, array $options) { return ['value' => $entity->getNumber()]; }
/** * @param Field|FieldText $entity * @param array $options * * @return array */ public function getTemplateOptions($entity, array $options) { return ['url' => $entity->getText(), 'text' => $entity->getText(), 'new_tab' => $options['new_tab'], 'follow' => $options['follow']]; }