Issue Bug Closed

#4267Registration for classes that provide additional fields does not bind those classes to specific task types

Ingo Renner 08/18/09, 18:19 updated 12/10/13, 01:26

Description

Current you register a class to provide additional task editing fields like this:

$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['scheduler']['additionalFields'][] = 'tx_solr_scheduler_OptimizeTaskSolrServerField';

This does not bind the class to a specific task and thus the class needs to check whether it’s called for the task it is meant to provide the additional fields for. This check can be saved by binding these field providers to respective tasks:

$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['scheduler']['additionalFields']['optimizeTask'][] = 'tx_solr_scheduler_OptimizeTaskSolrServerField';

By doing so we would move the check for additional field providers from external extensions to the scheduler where it makes more sense instead of having each field provider having to check the task. I don’t think it’d be a performance issue as there’re probably only a limited number of tasks available in an installation, but nevertheless it seems to be cleaner to bind the field provider to their tasks.

Reviews 0

No change resolves or names this issue in its commit message, and no comment links one.