Project

General

Profile

Actions

Bug #72926

closed

IconFactory getIconForRecord might not produce correct icon in ajax (inline) context

Added by Andreas Allacher over 8 years ago. Updated over 6 years ago.

Status:
Closed
Priority:
Must have
Assignee:
Category:
Backend API
Target version:
Start date:
2016-01-25
Due date:
% Done:

100%

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

Description

IconFactory uses IconRegistry isRegisterd method in mapRecordTypeToIconIdentifier to determine correct record icon.
This might fail to determine the correct icon as IconRegistry is Singleton and only initializes TCA icons in constructor (if TCA is already set) or in getIconConfigurationByIdentufier.

However, getIconConfigurationByIdentufier happens after the isRegistered checks in mapRecordTypeToIconIdentifier.

To ensure it will also work correctly in various extensions, it might be best to do the initialize checks in all methods in IconRegistry as e.g. getAllRegisteredIconIdentifiers should also include TCA icons, if they weren't initialized prior.

Actions

Also available in: Atom PDF