Hi,
Is it possible to map an IList<PointerItem>
property of entity type ProductsProduct to a List<Variant>
?
I’ve tried this with no success:
var favoriteItems = person.Fields.GetValue<IList<PointerItem>>("FavoriteItems")?.Select(x => x.MapTo<Variant>()).ToList();
Litium version: 7.2
NilsN
2
The pointer will return a base product, so you can map to BaseProduct
with the EntitySystemId
.
var favoriteItems = person.Fields.GetValue<IList<PointerItem>>("FavoriteItems").Select(x => x.EntitySystemId.MapTo<BaseProduct>()).ToList();
Thanks Nils. I didn’t notice that it was base products in the list. Any plans to add support for picking variants in future releases?
1 Like
system
Closed
4
This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.