[TYPO3-mvc] Relation to fe_user / Tx_Extbase_Domain_Model_FrontendUser
Kevin Ulrich Moschallski
km at 3digit.de
Fri Jan 14 17:06:50 CET 2011
Hi Stephan,
did you configure the single table inheritance in your setup?
Regards,
Kevin
On 2011-01-14 16:28:56 +0100, Stephan Petzl said:
> Hi there!
>
> I could not find any hints on how to implement a simple relation to
> Tx_Extbase_Domain_Model_FrontendUser.
>
> I tried the most obvious aproach, my game-model looks like that:
>
> class Tx_MyExt_Domain_Model_Game extends
> Tx_Extbase_DomainObject_AbstractEntity {
> ...
> /**
> * user
> *
> * @var Tx_Extbase_Domain_Model_FrontendUser $user
> */
> protected $user;
> /**
> * Setter for user
> *
> * @param Tx_Extbase_Domain_Model_FrontendUser $user user
> * @return void
> */
> public function setUser(Tx_Extbase_Domain_Model_FrontendUser $user) {
> $this->user = $user;
> }
>
> /**
> * Getter for user
> *
> * @return Tx_Extbase_Domain_Model_FrontendUser user
> */
> public function getUser() {
> return $this->user;
> }
> ...
>
> In my template I tried to <f:debug>{game}</f:debug> with following
> result: the user property is empty:
>
> Tx_AjadoDpm_Domain_Model_Game Object
> (
> [height:protected] => 300
> [user:protected] =>
> [time:protected] => 2000
> ...
> )
>
> Any ideas what I'm missing?
More information about the TYPO3-project-typo3v4mvc
mailing list