Warning: Undefined array key "type" in Drupal\field_ui\Form\EntityDisplayFormBase->buildFieldRow()

Created on 5 March 2024, 10 months ago

Problem/Motivation

Steps to reproduce

1 - Clean install + patches
2 - Create and sell a ticket
3 - visit admin/structure/commerce_ticket_types/manage/default/display

The following two errors appear: (I have verbose and all errors on etc)

Warning: Undefined array key "type" in Drupal\field_ui\Form\EntityDisplayFormBase->buildFieldRow() (line 362 of core/modules/field_ui/src/Form/EntityDisplayFormBase.php).

Drupal\field_ui\Form\EntityDisplayFormBase->buildFieldRow(Object, Array, Object) (Line: 41)
Drupal\field_ui\Form\EntityViewDisplayEditForm->buildFieldRow(Object, Array, Object) (Line: 227)
Drupal\layout_builder\Form\LayoutBuilderEntityViewDisplayForm->buildFieldRow(Object, Array, Object) (Line: 213)
Drupal\field_ui\Form\EntityDisplayFormBase->form(Array, Object) (Line: 47)
Drupal\layout_builder\Form\LayoutBuilderEntityViewDisplayForm->form(Array, Object) (Line: 107)
Drupal\Core\Entity\EntityForm->buildForm(Array, Object) (Line: 40)
Drupal\layout_builder\Form\LayoutBuilderEntityViewDisplayForm->buildForm(Array, Object, Object)
call_user_func_array(Array, Array) (Line: 536)
Drupal\Core\Form\FormBuilder->retrieveForm('entity_view_display_edit_form', Object) (Line: 283)
Drupal\Core\Form\FormBuilder->buildForm(Object, Object) (Line: 73)
Drupal\Core\Controller\FormController->getContentResult(Object, Object) (Line: 39)
Drupal\layout_builder\Controller\LayoutBuilderHtmlEntityFormController->getContentResult(Object, Object)
call_user_func_array(Array, Array) (Line: 123)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 627)
Drupal\Core\Render\Renderer->executeInRenderContext(Object, Object) (Line: 121)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->wrapControllerExecutionInRenderContext(Array, Array) (Line: 97)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 181)
Symfony\Component\HttpKernel\HttpKernel->handleRaw(Object, 1) (Line: 76)
Symfony\Component\HttpKernel\HttpKernel->handle(Object, 1, 1) (Line: 58)
Drupal\Core\StackMiddleware\Session->handle(Object, 1, 1) (Line: 48)
Drupal\Core\StackMiddleware\KernelPreHandle->handle(Object, 1, 1) (Line: 28)
Drupal\Core\StackMiddleware\ContentLength->handle(Object, 1, 1) (Line: 32)
Drupal\big_pipe\StackMiddleware\ContentLength->handle(Object, 1, 1) (Line: 106)
Drupal\page_cache\StackMiddleware\PageCache->pass(Object, 1, 1) (Line: 85)
Drupal\page_cache\StackMiddleware\PageCache->handle(Object, 1, 1) (Line: 48)
Drupal\Core\StackMiddleware\ReverseProxyMiddleware->handle(Object, 1, 1) (Line: 51)
Drupal\Core\StackMiddleware\NegotiationMiddleware->handle(Object, 1, 1) (Line: 36)
Drupal\Core\StackMiddleware\AjaxPageState->handle(Object, 1, 1) (Line: 51)
Drupal\Core\StackMiddleware\StackedHttpKernel->handle(Object, 1, 1) (Line: 704)
Drupal\Core\DrupalKernel->handle(Object) (Line: 19)

Warning: Undefined array key "label" in Drupal\field_ui\Form\EntityViewDisplayEditForm->buildFieldRow() (line 53 of core/modules/field_ui/src/Form/EntityViewDisplayEditForm.php).

Drupal\field_ui\Form\EntityViewDisplayEditForm->buildFieldRow(Object, Array, Object) (Line: 227)
Drupal\layout_builder\Form\LayoutBuilderEntityViewDisplayForm->buildFieldRow(Object, Array, Object) (Line: 213)
Drupal\field_ui\Form\EntityDisplayFormBase->form(Array, Object) (Line: 47)
Drupal\layout_builder\Form\LayoutBuilderEntityViewDisplayForm->form(Array, Object) (Line: 107)
Drupal\Core\Entity\EntityForm->buildForm(Array, Object) (Line: 40)
Drupal\layout_builder\Form\LayoutBuilderEntityViewDisplayForm->buildForm(Array, Object, Object)
call_user_func_array(Array, Array) (Line: 536)
Drupal\Core\Form\FormBuilder->retrieveForm('entity_view_display_edit_form', Object) (Line: 283)
Drupal\Core\Form\FormBuilder->buildForm(Object, Object) (Line: 73)
Drupal\Core\Controller\FormController->getContentResult(Object, Object) (Line: 39)
Drupal\layout_builder\Controller\LayoutBuilderHtmlEntityFormController->getContentResult(Object, Object)
call_user_func_array(Array, Array) (Line: 123)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 627)
Drupal\Core\Render\Renderer->executeInRenderContext(Object, Object) (Line: 121)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->wrapControllerExecutionInRenderContext(Array, Array) (Line: 97)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 181)
Symfony\Component\HttpKernel\HttpKernel->handleRaw(Object, 1) (Line: 76)
Symfony\Component\HttpKernel\HttpKernel->handle(Object, 1, 1) (Line: 58)
Drupal\Core\StackMiddleware\Session->handle(Object, 1, 1) (Line: 48)
Drupal\Core\StackMiddleware\KernelPreHandle->handle(Object, 1, 1) (Line: 28)
Drupal\Core\StackMiddleware\ContentLength->handle(Object, 1, 1) (Line: 32)
Drupal\big_pipe\StackMiddleware\ContentLength->handle(Object, 1, 1) (Line: 106)
Drupal\page_cache\StackMiddleware\PageCache->pass(Object, 1, 1) (Line: 85)
Drupal\page_cache\StackMiddleware\PageCache->handle(Object, 1, 1) (Line: 48)
Drupal\Core\StackMiddleware\ReverseProxyMiddleware->handle(Object, 1, 1) (Line: 51)
Drupal\Core\StackMiddleware\NegotiationMiddleware->handle(Object, 1, 1) (Line: 36)
Drupal\Core\StackMiddleware\AjaxPageState->handle(Object, 1, 1) (Line: 51)
Drupal\Core\StackMiddleware\StackedHttpKernel->handle(Object, 1, 1) (Line: 704)
Drupal\Core\DrupalKernel->handle(Object) (Line: 19)

🐛 Bug report
Status

Active

Version

2.0

Component

Code

Created by

🇬🇧United Kingdom martin@manarock.co.uk

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

  • Issue created by @martin@manarock.co.uk
  • 🇬🇧United Kingdom martin@manarock.co.uk

    Note:

    This may be solved - the field QR Code had a format of 'bootstrap image gallery' as the default for the formatter on all the displays. (/admin/structure/commerce_ticket_types/manage/default/display).

    Enabling this field for all 4 (receipt, QR code label PDF, Default) setting it to 'Ticket QR code', saving and then disabling it again for QR Code Label and Receipt seemed to solve the issue.

    As an aside, I think I understand that:

    - PDF is the attached PDF to the receipt
    - Receipt is the email with ticket (pdf) attached when you resend a ticket as admin
    - Default is the display you see on /commerce_ticket/[uuid]

    I would assume that QR Code label is the 'wrapper' around the QR Code itself? (if my variation title is 'single entry' is this the value of that name field?

  • 🇬🇪Georgia almador

    Same errors on the page:
    admin/structure/commerce_ticket_types/manage/default/display

Production build 0.71.5 2024