2009-12-16 78 views
0

我已經創建了一個帶有內容類型的SharePoint日曆:可用和不可用。 「全天事件」, 「重複」和「工作區」字段在新內容類型中不可用。我需要「全天事件」和「恢復」字段。我沒有在這個日曆上使用「Event」內容類型。 全日事件和相關列應該在新內容類型上可用嗎?
如果是這樣,我可能做錯了什麼? 如果不是,我如何獲得所需的列到新的內容類型?日曆和內容類型

謝謝

回答

0

您的內容是從事件內容類型派生出來的嗎?我相信隱藏事件內容類型,但使用功能創建您的內容類型並使用內容類型標識層次結構讓您的可用/不可用內容類型從Sharepoint事件內容類型派生,可以解決您的問題。刪除您不需要的任何字段(網站欄)。

使用下面的xml片段來創建派生的內容類型。恕我直言,當您計劃創建超過1個版本的ctype時,最好先創建一個從開箱即用的sharepoint ctype派生的基本內容類型。

<!-- 0x0102 is the sharepoint event content type's id, 
00 is a splitter, 
the rest is a guid that you generate, stripped of dashes and {} 
i.e. {54646609-853E-4f28-B4F8-B6258DBFD632} 
add 01, 02, etc. at the end to create ctypes derived from this base ctype--> 
<ContentType ID="0x01020054646609853E4f28B4F8B6258DBFD632" 
      Name="Event Derived Base Content Type" 
      Description="This serves as a base for all your event ctype derived ctypes" 
      Group="Group the ctype should fall under in ctypes site settings page"> 
    <FieldRefs> 
    </FieldRefs> 
</ContentType> 

<!-- by adding 01 you create a new, specific purpose ctype--> 
<ContentType ID="0x01020054646609853E4f28B4F8B6258DBFD63201" 
      Name="Available" 
      Description="Your description" 
      Group="Name of group"> 
    <FieldRefs> 
    </FieldRefs> 
</ContentType> 

<!-- same for 02 --> 
<ContentType ID="0x01020054646609853E4f28B4F8B6258DBFD63202" 
      Name="Unavailable" 
      Description="Your description" 
      Group="Name of group"> 
    <FieldRefs> 
    </FieldRefs> 
</ContentType>