Hmm, also entweder ist mein Problem so komplex, dass niemand ne Idee hat, oder 
ich hab zu wenig Infos eingestellt. Also anbei nochmal der aktuelle Stand der 
Dinge!

Also so sieht das ganze bei mir momentan aus:
SQL


   image int(11) unsigned NOT NULL default '0',


TCA


   'image' => array(
   'exclude' => 1,
   'label' => 
'LLL:EXT:gv_test/Resources/Private/Language/locallang_db.xlf:tx_gvtest_domain_model_test.image',
   'config' => 
\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::getFileFieldTCAConfig(
   'image',
   array('maxitems' => 10),
   $GLOBALS['TYPO3_CONF_VARS']['GFX']['imagefile_ext']
   ),
   ),


Model


   class Test extends \TYPO3\CMS\Extbase\DomainObject\AbstractEntity {

   /**
   * image
   *
   * @var 
\TYPO3\CMS\Extbase\Persistence\ObjectStorage<\TYPO3\CMS\Extbase\Domain\Model\FileReference>
   */
   protected $image;

   /**
   * __construct
   *
   * @return AbstractObject
   */
   public function __construct() {
   $this->image = new \TYPO3\CMS\Extbase\Persistence\ObjectStorage();
   }

   /**
   * get the Image
   *
   * @return \TYPO3\CMS\Extbase\Persistence\ObjectStorage
   */
   public function getImages() {
   return $this->image;
   }

   /**
   * sets the Image
   *
   * @param \TYPO3\CMS\Extbase\Persistence\ObjectStorage $image
   *
   * @return void
   */
   public function setImages($image) {
   $this->image = $image;
   }
   }


Fluid


   <table class="tx-gv-test" >
   <tr>
   <td>
   <f:translate key="tx_gvtest_domain_model_test.image" />
   </td>
   <td>
   <f:debug>{test}</f:debug>
   <f:for each="{test.image}" as="thisimage">
   <f:debug>{thisimage.originalResource}</f:debug>
   </f:for>
   </td>
   </tr>
   </table>


Debug Ausgabe


   Extbase Variable Dump

   GunVog\GvTest\Domain\Model\Testprototypepersistent entity (uid=1, pid=59)
   image => TYPO3\CMS\Extbase\Persistence\ObjectStorageprototypeobject (2 items)
   000000006df6792d000000007757f5cc => 
TYPO3\CMS\Extbase\Domain\Model\FileReferenceprototypepersistent entity (uid=120, 
pid=59)
   originalResource => NULL
   uid => 120 (integer)
   _localizedUid => 120 (integer)modified
   _languageUid => 0 (integer)modified
   _versionedUid => 120 (integer)modified
   pid => 59 (integer)
   000000006df6792a000000007757f5cc => 
TYPO3\CMS\Extbase\Domain\Model\FileReferenceprototypepersistent entity (uid=121, 
pid=59)
   originalResource => NULL
   uid => 121 (integer)
   _localizedUid => 121 (integer)modified
   _languageUid => 0 (integer)modified
   _versionedUid => 121 (integer)modified
   pid => 59 (integer)
   uid => 1 (integer)
   _localizedUid => 1 (integer)modified
   _languageUid => 0 (integer)modified
   _versionedUid => 1 (integer)modified
   pid => 59 (integer)


Die foreach Schleife wird überhaupt nicht durchlaufen und originalResource ist 
NULL. Hmmm :(
_______________________________________________
TYPO3-german mailing list
TYPO3-german@lists.typo3.org
http://lists.typo3.org/cgi-bin/mailman/listinfo/typo3-german

Antwort per Email an