2 namespace TYPO3\CMS\Scheduler
;
5 * This file is part of the TYPO3 CMS project.
7 * It is free software; you can redistribute it and/or modify it under
8 * the terms of the GNU General Public License, either version 2
9 * of the License, or any later version.
11 * For the full copyright and license information, please read the
12 * LICENSE.txt file that was distributed with this source code.
14 * The TYPO3 project - inspiring people to share!
18 * Interface for classes who want to provide additional fields when adding a task
20 * @author Ingo Renner <ingo@typo3.org>
22 interface AdditionalFieldProviderInterface
{
25 * Gets additional fields to render in the form to add/edit a task
27 * @param array $taskInfo Values of the fields from the add/edit task form
28 * @param \TYPO3\CMS\Scheduler\Task\AbstractTask $task The task object being edited. Null when adding a task!
29 * @param \TYPO3\CMS\Scheduler\Controller\SchedulerModuleController $schedulerModule Reference to the scheduler backend module
30 * @return array A two dimensional array, array('Identifier' => array('fieldId' => array('code' => '', 'label' => '', 'cshKey' => '', 'cshLabel' => ''))
32 public function getAdditionalFields(array &$taskInfo, $task, \TYPO3\CMS\Scheduler\Controller\SchedulerModuleController
$schedulerModule);
35 * Validates the additional fields' values
37 * @param array $submittedData An array containing the data submitted by the add/edit task form
38 * @param \TYPO3\CMS\Scheduler\Controller\SchedulerModuleController $schedulerModule Reference to the scheduler backend module
39 * @return bool TRUE if validation was ok (or selected class is not relevant), FALSE otherwise
41 public function validateAdditionalFields(array &$submittedData, \TYPO3\CMS\Scheduler\Controller\SchedulerModuleController
$schedulerModule);
44 * Takes care of saving the additional fields' values in the task's object
46 * @param array $submittedData An array containing the data submitted by the add/edit task form
47 * @param \TYPO3\CMS\Scheduler\Task\AbstractTask $task Reference to the scheduler backend module
50 public function saveAdditionalFields(array $submittedData, \TYPO3\CMS\Scheduler\Task\AbstractTask
$task);