在我的extbase扩展中,我有模型“Item” . 我得到像这样的图像
/**
* image
*
* @var \TYPO3\CMS\Extbase\Persistence\ObjectStorage<\TYPO3\CMS\Extbase\Domain\Model\FileReference>
* @cascade remove
*/
protected $image = NULL;
在表"sys_file_reference"和TCA中我'm added filed 1263499 . It'在后端工作 . 在流体中,我可以从sys_file_reference获取图像uid,如 {image.uid}
如何从表sys_file_reference获取流体中的"preview"?该字段在表格中设置 .
1 回答
您需要提供自己的FileReference类,该类具有您的预览属性并扩展Extbase模型:
然后在
$image
属性中使用此类:在TypoScript中告诉extbase将您的类映射到sys_filke_reference表:
代码未经测试,但应指向正确的方向 .