2017-02-23 60 views

回答

0

好吧,我做到了在TS那樣:

lib.categories = CONTENT 
lib.categories { 
    table = sys_category 
    select { 
     pidInList = 1 
     selectFields = sys_category.uid 
     join = sys_category_record_mm on sys_category_record_mm.uid_local = sys_category.uid 
     where.field = recordUid 
     where.wrap = sys_category_record_mm.uid_foreign=| 
    } 
    renderObj = COA 
    renderObj { 
     1 = TEXT 
     1 { 
      field = uid 
      stdWrap.noTrimWrap = | 
     } 
    } 
} 

和流體模板方式:

<div class="wrapper {f:if(condition: '{f:cObject(typoscriptObjectPath: \'lib.categories\', data: {recordUid: data.uid})} == 2', then: 'category', else: 'default')}"></div> 
0

是的,我可以告訴你。

身體必須至少30個字符;您輸入25