2017-02-20 2 views
0

TYPO3 Extension의 "bootstrap_package"에서 TYPO3 Extension Repository에서 사용할 수있는 다음 스 니펫을 보았습니다.ContentElement를 참조로 삽입하면 TypoScript Datapocessor가 작동하지 않는 것 같습니다.

dataProcessing { 
    10 = TYPO3\CMS\Frontend\DataProcessing\DatabaseQueryProcessor 
    10 { 
     table = tx_bootstrappackage_accordion_item 
     where { 
      data = field:uid 
      intval = 1 
      wrap = tt_content=| 
     } 
     orderBy = sorting 
     dataProcessing { 
      10 = TYPO3\CMS\Frontend\DataProcessing\FilesProcessor 
      10 { 
       references.fieldName = media 
      } 
     } 
    } 
} 

아코디언 컨텐츠 요소에 속하는 테이블에서 레코드 (아코디언 항목)를 가져 오는 중입니다. 그게 잘 작동합니다. 그러나이 Accordion에 대한 참조를 페이지의 어딘가에 삽입하면 레코드를 가져올 수 없습니다.

이 코드를 어떻게 변경해야합니까?

고마워요.

답변

1

나는 이런 식으로 그것을 사용 : (pidInList.field는 = PID < <이없는)

tt_content.xy =< lib.default 
tt_content.xy { 
    templateName = CE_Stage 
    dataProcessing { 
     30 = TYPO3\CMS\Frontend\DataProcessing\DatabaseQueryProcessor 
     30 { 
      table = tx_xy_slider 
      pidInList.field = pid 
      where { 
       data = field:uid 
       intval = 1 
       wrap = tt_content=| 
      } 

      orderBy = sorting 
      as = slides 
      dataProcessing { 
       10 = TYPO3\CMS\Frontend\DataProcessing\FilesProcessor 
       10 { 
        references.fieldName = image 
        as = images 
       } 
      } 
     } 
    } 
}