From 50512e47c3bcce43431431c9d5e1ceb90207a8bf Mon Sep 17 00:00:00 2001 From: Eli-T <Eli-T@516878.no-reply.drupal.org> Date: Tue, 19 Nov 2019 09:43:21 +0000 Subject: [PATCH] Issue #3095182 by Eli-T: Allow use the existing text_default field formatter as the for typed resource object fields --- jsonapi_reference.module | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/jsonapi_reference.module b/jsonapi_reference.module index c1600ea..9b7f9ef 100644 --- a/jsonapi_reference.module +++ b/jsonapi_reference.module @@ -29,3 +29,10 @@ function jsonapi_reference_help($route_name, RouteMatchInterface $route_match) { function jsonapi_reference_field_widget_info_alter(array &$info) { $info['string_textfield']['field_types'][] = 'typed_resource_object'; } + +/** + * Implements hook_field_formatter_info_alter(). + */ +function jsonapi_reference_field_formatter_info_alter(array &$info) { + $info['text_default']['field_types'][] = 'typed_resource_object'; +} -- GitLab