Hi guys,
I am trying to set up the reorder using Express Buy (logic from OrderViewSearchList.cshtml but I am getting some issues.
I have tried addin a product to an order then reorder.
The message I get is "The product "XXX" (XXX), that was a part of this order, seems to have been removed. Contact the shop for further information.".
Obviously, the product is active because I just ordered it.
Looking at the code, it all comes down to this condition:
The product created from the Orderline does not have a PrimaryOrDefaultGroup, although the product is assigned correctly to a Group from the shop. I have also tried setting the primary group manually on a product, but I got the same error.
It is probably related to how the ProductViewModel is generated based on the Orderline.
How do I solve it? Should I change this logic:
To retrieve an OrderViewModel instead?
Thank you,
Adrian