Hi:
I am trying to get the orders complete using c# code.
The reason is that the TPV that we use sometimes does not redirect to our website.
So what i do is receive the transaction log of the TPV and complete the order by code with the log information.
The way that i complete the order is the next:
if (order != null) { //orderService.UpdateCartToOrder(order); orderService.Complete(order); order.StateId = "OS1"; orderService.Save(order); Dynamicweb.Logging.LogManager.Current.GetLogger("RedsysLog").Log("Order Complete"); }
If i use the updateCartToOrder function it does not complete the order and generates other orderId.
With this code, order are complete but i get this error:
The error is in the line orderService.Save(order);
Is there any way to complete the order with initial state?
Regards ,
Jose