Project

General

Profile

Actions

Bug #76232

closed

Story #69617: FormEngine bugs

IconFactory::getIconForRecord() throws an exception in some cases (contrary to former feedback)

Added by Petra Arentzen over 8 years ago. Updated about 6 years ago.

Status:
Closed
Priority:
Should have
Category:
-
Target version:
-
Start date:
2016-05-18
Due date:
% Done:

100%

Estimated time:
TYPO3 Version:
7
PHP Version:
Tags:
Complexity:
Is Regression:
No
Sprint Focus:

Description

Contrary to my former feedback for bug #75271 the exception occurred again (Now tested in 7.6.6 and 7.6.7)

I can tell that the problem occurrs with the following TCA column configuration:

                'type' => 'group',
                'internal_type' => 'db',
                'allowed' => 'my_relation_table',
                'prepend_tname' => 0,
               'show_thumbs' => '1',

It's because in TYPO3\CMS\Backend\Form\Element\GroupElement::render() line 275 spliting is done for db value

list($this_table, $this_uid) = BackendUtility::splitTable_Uid($recordParts[0]);

But because 'prepend_tname' is false there is no table name. The value then only contains a number but not a table name.

I added this after the line obove to solve the problem and it worked for me!


                    // if 'prepend_tname' is false $this_table is empty
                    if (!$this_table) {
                        $this_table = reset($allowed);
                    }


Related issues 1 (0 open1 closed)

Related to TYPO3 Core - Bug #75271: TYPO3\CMS\Core\Imaging\IconFactory::getIconForRecord() throws an exception in some casesClosed2016-03-25

Actions
Actions

Also available in: Atom PDF