Hi,
I want to show 'Art. Ref.' instead of 'Number' for my products at the frontend, so attribute Art_ref instead of Product_Number. How do I do this by adjusting for example the Swift_ProductNumber.cshtml template?
I tried the following approaches to access the Art_ref field, but none have worked:
- Direct Property Access: Tried @product.Art_ref, but it resulted in an error as Art_ref is not a direct property of ProductViewModel.
- Tags and GetString: Attempted @GetString("Ecom:Product.Field.Art_ref") and @Html.Raw(@GetString("Ecom:Product.Field.Art_ref")), but these methods and tags were not available in the current context.
- Access via ProductFields Dictionary: Tried retrieving Art_ref using @product.ProductFields["Art_ref"].Value as string, but the field was either not found or not accessible.
Could you advise on how to properly access the Art_ref field in this context? Afterwards I have to replace it everywhere, but I want to start at the detail page of a product.
Kind regards,
Caro De Weze