[TYPO3-mvc] tx_sv_authbase Authentication Service and ExtBase - TS Configuration Problems

Alexander heim alexander at alexander-heim.com
Tue Dec 27 10:36:05 CET 2011


Hmmm. I tried

     $dispatcher->dispatch($request, $response);
or
     $this->myCommandControllerObject->processRequest($request,$response);

my function is called. Thats fine. But it does not solve my main problem 
at all. "newRecordStoragePid" is still completly ignored.


Alex





Am 27.12.2011 09:14, schrieb Alexander heim:
> Hi Claus,
>
> sorry for my late answer.
> I wrote a CommandController what extends 
> Tx_Extbase_MVC_Controller_CommandController. It has the two functions 
> for getting a user and authenticate the user. Nothing special. But I 
> could not find any additional positive aspect with it. So I used 
> $this->objectManager->get('Tx_Myextension_Command_MyCommandController') to 
> get the controller. I did not initialized anything special before. But 
> it seems like, that I should do this. Or how should the 
> CommandController be used? Do I need to use a dispatcher? If yes, I 
> would think to use it this way ... but somehow I have the feeling, it 
> is wrong:
>
>         $request = 
> $this->objectManager->get('Tx_Extbase_MVC_CLI_Request');
>         $dispatcher = 
> $this->objectManager->get('Tx_Extbase_MVC_Dispatcher');
>         $response = 
> $this->objectManager->get('Tx_Extbase_MVC_CLI_Response');
>         
> $request->setControllerObjectName('TxCommand_Myextension__MyextensionCommandController');
>         
> $request->setControllerCommandName('getOrCreateFeUserAndGetFeUserId');
>         $request->setArguments(array("login"=>$this->login['uname']));
>         $dispatcher->dispatch($request, $response);
>
> I also saw, that there are two public functions "canProcessRequest()" 
> and "processRequest()". Would it be better to use them? Is Extbase 
> intialized right at this point and is able to get the informations 
> from TypoScript? So like:
>
>
>         module.tx_Myextension.persistence.storagePid = 9
>         module.tx_Myextension.persistence.newRecordStoragePid = 9
>
> The Function "getOrCreateFeUserAndGetFeUserId" is a function from 
> "TxCommand_Myextension__MyextensionCommandController" and returns 
> false or the ID of the Frontend User of the given login.
>
> If I use dispatch or processRequest ... where is the result of the 
> called function stored? Should I use "output()" inside the command 
> controller to return the result?
>
> I know, a lot of questions, but I tried to search around inside the 
> scheduler, but could not find a way to adapt it to my needs. I do not 
> need the scheduler at this point or want to have access to the 
> function from commandline. I just hope, this could be a good 
> workaround, to make the functions available to the classical auth 
> service.
>
>
> Big thank you for your help
> Alex
>
>
>
> _______________________________________________
> TYPO3-project-typo3v4mvc mailing list
> TYPO3-project-typo3v4mvc at lists.typo3.org
> http://lists.typo3.org/cgi-bin/mailman/listinfo/typo3-project-typo3v4mvc



More information about the TYPO3-project-typo3v4mvc mailing list