Closed (fixed)
Project:
Viewfield
Version:
8.x-3.x-dev
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
30 Jul 2019 at 14:37 UTC
Updated:
13 Aug 2019 at 20:39 UTC
Jump to comment: Most recent
When attempting to manage the layout of a page using Layout Builder, the following errors are thrown.
Notice: Undefined index: display_id in Drupal\viewfield\Plugin\Field\FieldFormatter\ViewfieldFormatterDefault->viewElements() (line 130 of modules/custom/viewfield/src/Plugin/Field/FieldFormatter/ViewfieldFormatterDefault.php).
Notice: Undefined index: arguments in Drupal\viewfield\Plugin\Field\FieldFormatter\ViewfieldFormatterDefault->viewElements() (line 131 of modules/custom/viewfield/src/Plugin/Field/FieldFormatter/ViewfieldFormatterDefault.php).
Determine how to display a placeholder for Viewfields and correct these errors.
Comments
Comment #3
jerdavisAdded conditionals to viewElements(). This results in an empty element when sufficient information isn't available and renders a placeholder. If you're controlling layout of an individual piece of content you see the view results as expected.