/**
  *
  * @param TYPO3\CMS\Core\Resource\File $media
  */
 private function initFalFile($media)
 {
     $this->record = $media->getProperties();
     $this->uid = $media->getUid();
     $this->record['fal_file'] = '1';
     // Das wird per TS ausgewertet. Die UID ist KEINE Referenz
     $this->record['uid_local'] = $media->getUid();
     $this->record['file_path'] = $media->getPublicUrl();
     $this->record['file_abs_url'] = tx_rnbase_util_Misc::getIndpEnv('TYPO3_SITE_URL') . $this->record['file_path'];
 }
Ejemplo n.º 2
0
 /**
  * @test
  */
 public function updatePropertiesDiscardsUidIfAlreadySet()
 {
     $fixture = new \TYPO3\CMS\Core\Resource\File(array('uid' => 1, 'identifier' => '/test'), $this->storageMock);
     $fixture->updateProperties(array('uid' => 3));
     $this->assertEquals(1, $fixture->getUid());
 }