Developer forum

Forum » Development » CheckoutDoneOrderIsComplete ignored

CheckoutDoneOrderIsComplete ignored

Gonçalo Assunção
Reply

Hello all,

I have a website where I'm working with the Live Integration project, and I have a custom Discount Provider. Both these dll subscribe to the same notifier:Dynamicweb.Notifications.eCommerce.Cart.CheckoutDoneOrderIsComplete.

The issue is that when I insert a voucher in the checkout process, the LiveIntegration subscriber is ignored. It only subscribes to the DiscountProvider.

I've removed the Discount Provider dll from the site, and when I complete an order, the Live Integration subscriber is triggered.

 

I'm attaching the Discount Provider event subscriber just to make sure that I'm not doing anything that will override the Live Integration Subscriber.


Thank you in advance
'Gonzalo'

DiscountProviderPrint.jpg

Replies

 
Nicolai Høeg Pedersen
Reply

Hi Goncalo

You might want to take a look at this thread:

http://developer.dynamicweb.com/forum/ecommerce-standard-features/epay-checkoutdoneorderiscomplete-event-not-fired.aspx

I thnik the problem is the context in your checkouthandler notification subscriber in the discount provider. Try replacing the code with a logging line instead and see if it gets fired.

 
Gonçalo Assunção
Reply

Hi Nicolai,

Thank you for your anwser!

I've completed two orders (one without a voucher and one with a valid discount voucher), and checked the Ecom Log. You can check the log for both orders in the attachement. This is the development solution.

The second order wasn't exported to the ERP.

In my local solution (same database and same Application version), I did the same orders and the order with the valid voucher was exported... In the code, both events are being fired.

 

Thank you in advance

Kind Regards
'Gonzalo'

Ecom_Log.jpg
 
Nicolai Høeg Pedersen
Reply

So you got the issue solved?

 
Gonçalo Assunção
Reply

Hi Nicolai,

Sorry for not making myself clear with this. In my local solution, where I can debug it in Visual Studio, I can see that when I finish an order with a voucher code inserted, the code reaches both event notifiers. And if I check the Live Integration Log file, I can see that the order was exported with success to the ERP.

But, in the dev site, with the same situation, the order isn't exported to the ERP. If I don't insert a voucher, the order is exported, but if I insert one, the order is not exported. The Live Integration 'CheckoutDoneOrderIsComplete' notifier is ignored. But only in the dev site.
As I said before, my local solution has the same database and same application version than the dev site, and both the dll (discount provider and Live Integration) have been uploaded to the dev site. Again, this works in the local solution but it doesn't work in the dev site. I just can't find the issue here.

 

Thank you.

Kind Regards
'Gonzalo'

 
Nicolai Høeg Pedersen
Reply

I'm affraid I cannot solve it either... Still I'm quite sure it could be some context related.

 
Gonçalo Assunção
Reply

Hi Nicolai,

The solution that I found for this is not the best one, but it works. Basicly I placed the discount provider in the same project as the Live Integration.  I'm running both methods in the same event subscriber.

 

Thank you

Kind Regards.
'Gonzalo'

 

You must be logged in to post in the forum