Class Frontend
- Namespace
- Dynamicweb.Frontend.ItemPublisher
- Assembly
- Dynamicweb.dll
Represents a frontend of the ItemPublisher module.
[AddInName("ItemPublisher")]
public class Frontend : ContentModule, IModule
- Inheritance
-
Frontend
- Implements
- Inherited Members
Properties
ItemFields
Gets or sets the fields of target item type.
public FieldMetadataCollection ItemFields { get; set; }
Property Value
ItemIdFromQuery
Gets the item Id specified via query string.
protected string ItemIdFromQuery { get; }
Property Value
ItemType
Gets or sets the target item type.
public ItemType ItemType { get; set; }
Property Value
ItemTypeFromQuery
Gets the item type specified via query string.
protected string ItemTypeFromQuery { get; }
Property Value
Mode
Gets the module view mode.
public ViewMode Mode { get; }
Property Value
Query
Gets or sets the query that defines items what will be selected.
public Query Query { get; set; }
Property Value
Methods
CreateRenderer()
Creates new renderer.
public virtual Renderer CreateRenderer()
Returns
- Renderer
Renderer.
GetContentBySettings(string)
Retrieves module content from specified settings.
public OutputResult GetContentBySettings(string settings)
Parameters
settings
stringA string with item publisher module settings.
Returns
- OutputResult
Module content.
Remarks
The method is used to render an item directly in a template without the use of a page or paragraph. There are some template tags related to it: Item.Render, Item.RenderList and razor version - @RenderItemList.
GetItemFields()
Returns the initial list of item fields to operate with.
protected virtual IEnumerable<string> GetItemFields()
Returns
- IEnumerable<string>
The list of item fields.
GetItemType(bool)
Returns target item metadata.
protected virtual ItemType GetItemType(bool isOriginal = false)
Parameters
isOriginal
boolIs it original item type needed or copy with selected field only.
Returns
- ItemType
Target item metadata.
GetItems()
Returns a list of items that needs to be rendered.
public virtual IEnumerable<ItemEntry> GetItems()
Returns
- IEnumerable<ItemEntry>
A list of items that needs to be rendered.
GetModuleContent()
Gets the content of ItemPublisher module.
public override OutputResult GetModuleContent()
Returns
- OutputResult
String representation of content
GetQuery()
Returns the query parsed from the current paragraph settings (and request).
protected virtual Query GetQuery()
Returns
- Query
Parsed query.
InitializeModule(Paragraph, PageView)
Initializes the module.
public override void InitializeModule(Paragraph renderingParagraph, PageView pageviewContext)