[TYPO3-english] Re: Command Controller: I can't execute a command that uses class repositories of my extension

christian ewigfrost christian-kulozik at gmx.net
Tue Nov 7 15:37:03 CET 2017


Here my TestTask.php:

<?php

namespace Cjk\Icingaconfgen\Tasks;

class TestTask extends \TYPO3\CMS\Scheduler\Task\AbstractTask
{

public function execute() {
$objectManager = \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance('TYPO3\\CMS\\Extbase\\Object\\ObjectManager');

$apprep = $objectManager->get(\Cjk\Icingaconfgen\Domain\Repository\HostRepository::class);

\TYPO3\CMS\Extbase\Utility\DebuggerUtility::var_dump($apprep->findByUid(1)); 

}

}


More information about the TYPO3-english mailing list