This project is read-only.

Custom DisplayType

Topics: Writing modules, Writing themes
Mar 3, 2013 at 5:33 PM
Edited Mar 3, 2013 at 5:34 PM
Can i use custom display type?

In cshtml:
var shape = _contentManager.BuildDisplay(item, "CustomDisplayType");
    <Match DisplayType="CustomDisplayType">
        <Place Parts_Title_Summary="Content:1" />
It does not work.
Mar 3, 2013 at 6:53 PM
You certainly can. Is it not working?
Mar 3, 2013 at 6:56 PM
Sorry, overlooked your last sentence.
Perhaps the Parts_Title_Summary shape is not rendered when the display type is not "Summary".
Try it by changing your to:
<Match DisplayType="CustomDisplayType">
        <Place Parts_Title="Content:1" />
And/or check the source code of the TitlePartDriver to see under what conditions what shapes are created.
Mar 4, 2013 at 12:30 AM
Need to be created Content.CustomDisplayType.cshtml