DevReach site: Modify the Detailed view of the Sessions template

The Detailed view widget template is used to display a single session in detail. You reach the Detailed view after you click a session the List view.

Open the Sessions Detailed view widget template for editing and paste the following code:

  • DataSource='<%# Eval("Speakers")%>' – sets all related speakers as a data source of the repeater.
  • <%# RelatedDataExtensions.GetDefaultUrl(Container.DataItem) %> - returns the default location of the item in the frontend – its canonical URL.
  • <%# Container.DataItem.GetItemsWithSameTaxons("Tags", "Telerik.Sitefinity.DynamicTypes.Model.DevReach.Session", 0, 5) %> – returns the first 5 sessions having the same tag as the current session.
  • <%# Container.DataItem.GetRelatedItemsCountByField("Attendees") %> - gets the count of the related items by the related data field name. The Attendees relation is also used to show the count of the attendees of a current session.

In order to use the above mentioned extension methods, you must add the following import: <%@ Import Namespace="Telerik.Sitefinity.RelatedData" %>

The following screenshot displays the final looks of the Session widget in detailed view:

Want to learn more?

Sign up for our free beginner training. Boost your credentials through advanced courses and certification.
Register for Sitefinity training and certification.

Was this article helpful?