I have a contentType (product) that has a taxonomy (function) field. The term taxonomy (product function term) has been configured to include the image field and description field.
I would like the product detail view to display an image with the name along with the name, but I cannot find it for access.
I created the following:
Taxonomy
- Commodity System
- Dictionary: Feat1, Feat2, Feat3
ContentTypes
Product
- Fields: Features (taxonomy)
Product Features Duration
- Fields: Description (HTML), Image (Image)
representation
Fields.Contrib.TaxonomyField-Features.cshtml
@if (Model.Terms.Count > 0) { <p class="taxonomy-field"> <span class="name">@name.CamelFriendly():</span> @(new HtmlString( string.Join(", ", terms.Select(t => Html.ItemDisplayLink(Html.Encode(t.Name), t.ContentItem ).ToString()).ToArray()) )) </p> } @if (Model.Terms.Count > 0) { <div> @foreach (var myTerm in Model.Terms) { @Display(???) } </div> }
What replace question marks? I thought it would be myTerm.Image, but this field does not exist in the dynamic object.
I attached the image of the designer.

source share