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

2017-11-07 Thread christian ewigfrost
Thank you very much, it seems to have worked flawlessly. But i had to change the line where i create the Typo3QuerySettings object to "'TYPO3\\CMS\\Extbase\\Persistence\\Generic\\Typo3QuerySettings'". I had not time to test it yet in its full extent, because i just got to work, but you saved

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

2017-11-07 Thread christian ewigfrost
Quote: christian ewigfrost (ewigfrost) wrote on Tue, 07 November 2017 16:14 Quote: christian ewigfrost (ewigfrost) wrote on Tue, 07 November 2017 16:08 > Quote: Mikel wrote on Tue, 07

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

2017-11-07 Thread christian ewigfrost
Quote: christian ewigfrost (ewigfrost) wrote on Tue, 07 November 2017 16:08 Quote: Mikel wrote on Tue, 07 November 2017 16:02 > The execute method needs a return statement. > Add return

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

2017-11-07 Thread christian ewigfrost
Quote: Mikel wrote on Tue, 07 November 2017 16:02 The execute method needs a return statement. Add return TRUE; add the end of your method. Thanks... It works. But the var dump returns

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

2017-11-07 Thread christian ewigfrost
Quote: christian ewigfrost (ewigfrost) wrote on Tue, 07 November 2017 15:37 Here my TestTask.php: get(\Cjk\Icingaconfgen\Domain\Repository\HostRepository::class); \TYPO3\CMS\Extbase\Utility\DebuggerUtility::var_dump($apprep->findByUid(1));

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

2017-11-07 Thread christian ewigfrost
It works now, it was my fault... But: I get an error when executing the saved task: Execution of task "Foobar Test ()" failed with the following message: Task failed to execute successfully. Class: Cjk\Icingaconfgen\Tasks\TestTask, UID: 5 ___

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

2017-11-07 Thread christian ewigfrost
Here my TestTask.php: get(\Cjk\Icingaconfgen\Domain\Repository\HostRepository::class); \TYPO3\CMS\Extbase\Utility\DebuggerUtility::var_dump($apprep->findByUid(1)); } } ___ TYPO3-english mailing list TYPO3-english@lists.typo3.org

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

2017-11-07 Thread christian ewigfrost
Sry, i'm an idiot... I forgot a semicolon in the line before.^^ It works now. ___ TYPO3-english mailing list TYPO3-english@lists.typo3.org http://lists.typo3.org/cgi-bin/mailman/listinfo/typo3-english

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

2017-11-07 Thread christian ewigfrost
Quote: Mikel wrote on Tue, 07 November 2017 15:18 > > Oops, an error occurred! > syntax error, unexpected 'DebuggerUtility' (T_STRING) Take the full namespace (or take a use statement at the beggining of your class):

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

2017-11-07 Thread christian ewigfrost
OK, i tried to do what you told me: I registered the task in the ext_localconf.php: $GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['scheduler']['tasks'][\Cjk\Icingaconfgen\Tasks\TestTask::class] = array( 'extension' => $_EXTKEY, 'title' => 'Foobar Test' ); I created a TestTask.php file in

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

2017-11-07 Thread christian ewigfrost
One thing i'm confused about: I already registered the CommandController in the ext_localconf.php like this: if (TYPO3_MODE === 'BE') { $GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['extbase']['commandControllers'][] = 'Cjk\\Icingaconfgen\\Command\\SimpleCommandController'; } So i need to

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

2017-11-07 Thread christian ewigfrost
..Also the part about: "The TypoScript needs to be present in the root page of your website for backend modules/CommandControllers to use them. I suggest you add the stuff to myext/Configuration/TypoScript/setup.txt and add the static template of your ext to the root page." ..Is something

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

2017-11-07 Thread christian ewigfrost
BTW: I used that Stackoverflow post as a reference: https://stackoverflow.com/questions/23068053/in-an-extbase-extension-how-to-access-the-persistence-layer-from-a-scheduler-ta/23077743#23077743 The problem is: I don't understand where to put the line "module.tx_yourext.persistence <

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

2017-11-07 Thread christian ewigfrost
Quote: Mikel wrote on Tue, 07 November 2017 13:18 Try to fetch a single record with findByUid instead of getting all with findAll. If you get a result, your repository has no records storage uid. You can set it global in TypoScript or you

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

2017-11-07 Thread christian ewigfrost
The task runs well enough, i tried this with creating a dummy file with some summy text in it with trying to access the repositories. It worked (even without execute()). But it seems i cannot access the repositories from the Command Controller. ___