Developer forum

Forum » Dynamicweb 10 » Missing itempublisher templates

Missing itempublisher templates

Niels Christian Aaes
Niels Christian Aaes
Reply

Hi,

I'm missing itempublisher templates in a brand new solution.
So I looked in github to download files from latest.
https://github.com/dynamicweb/Swift/releases/download/v2.0.0/Swift_v2.0.0_Files.zip
The itempublisher templates are also missing in this zip. (or am I looking the wrong places)

I'll download from another solution.

..NC


Replies

 
Niels Christian Aaes
Niels Christian Aaes
Reply

Well... I only have one from swift v1. That is not working in swift v2.

Anyone has the standard itemPublisher List.cshtml for swift v2?

Please...

..NC

 
Nicolai Pedersen Dynamicweb Employee
Nicolai Pedersen
Reply
This post has been marked as an answer

Hi NC

Swift 2 does not use Item publisher for anything, so there is no template for it in Swift 2.

The one in Swift 1 is specifically made for list articles. You can very simple make your own item publisher template:
 

@inherits Dynamicweb.Rendering.RazorTemplateBase<Dynamicweb.Rendering.RazorTemplateModel<Dynamicweb.Rendering.Template>>

@foreach (LoopItem item in GetLoop("ItemPublisher:Items.List"))
{
 string title = item.GetString("ItemPublisher:Item.Title");
 <h1>@title</h1>
 <pre>
 @item.TemplateTags()
 </pre>
}
Votes for this answer: 1
 
Niels Christian Aaes
Niels Christian Aaes
Reply

Thank you Nicolai

But I would recommend to add a simpel List  template to the ItemPublisher in the solution as standard.
Since we can choose the ItemPublisher App.

..NC

 

You must be logged in to post in the forum