[Flow] SOLVED silly issue on 'You need to use $propertyMappingConfiguration->allowProperties('__identity')'

mario chiari ml at mariochiari.net
Mon Aug 25 23:20:22 CEST 2014


yes, it was silly, just a missing annotation. Forgive and forget. Cheers
mario


Il giorno dom, 24/08/2014 alle 00.52 +0200, mario chiari ha scritto:
> Hi
> 
> I am trying to define a silly createAction as below and can't remember
> how to do:
> 
> createAction(\TYPO3\Blog\Domain\Model\Blog $blog) { 
> 
> $post = new \TYPO3\Blog\Domain\Model\Post();
>                      $post->setBlog($blog);
>                      $post->setTitle('aaa');
>  		     $post->setAuthor('aaa');
>                      $post->setMail('aaa');
>              	 
>      		$this->postRepository->add($post); 
>                 $blog->addpost($post);
>                 $this->blogRepository->update($blog); 
> 		$this->addFlashMessage('bla bla'); 
>                 $this->redirect('index');
> }
> 
> I get the error msg: 
> 
> Exception while property mapping for target type
> "Doctrine\Common\Collections\Collection<\TYPO3\Blog\Domain\Model\Post>",
> at property path "": It is not allowed to map property "__identity". You
> need to use $propertyMappingConfiguration->allowProperties('__identity')
> to enable mapping of this property.
> 
> Shame on me, but I do not remember how I do that.
> Thanks, Cheers
> mario 
> 
> ps is there a way to call an action as above from the command line?
> 




More information about the Flow mailing list