Try our conversational search powered by Generative AI!

Cancelling Order in CommerceManager v12.5.0 and Commerce v10.8.0

Vote:
 

Hello

When our customers cancels orders in the CommerceManager, all lineitems are cleared. Is there anyway I can change this behaviour?

Thank you in advance.

#196055
Aug 17, 2018 10:56
Vote:
 

Hi,

I couldn't reproduce this problem in my local with v12.5.0. I still see the line items of cancelled order. Any missing steps?

Anw, you can change the behaviour by creating a class inherits from DefaultPurchaseOrderProcessor class, an override the CancelOrder() method. Or even create a new class that implements IPurchaseOrderProcessor interface and implement your custom business there. Don't forget to register your custom implementation. However, please note that, the DefaultPurchaseOrderProcessor is marked as internal, do it at your own risk. My suggestion is not to do it if it's really needed, I couldn't reproduce this behavior.

#196059
Aug 17, 2018 11:42
Vote:
 

Not sure what you meant CommerceManager v12.5.0 and Commerce v10.8.0, the version should match each other. 

Do you have any custom code to handle the cancel process? 

#196062
Aug 17, 2018 12:15
Vote:
 

You're right, my CommerceManager is also v10.8.0. 

Futhermore, I can't any code that implements custom behaviour for order cancellation.

Here's an example of the line items before cancellation:

After cancellation:

#196069
Edited, Aug 17, 2018 13:00
Vote:
 

That sounds like a bug that was fixed in a later version. Can you try to upgrade to latest version and try again ? (assuming your commerce manager does not have any customization) 

#196070
Aug 17, 2018 13:03
Vote:
 

Thanks for the answer.

Was it fixed within the 10 version branch? Or do I have to go all the way up to Commerce 12 in order to get the fix?

#196072
Aug 17, 2018 13:06
Vote:
 

I am ... not sure. It sounds like a bug to me, but I can't remember which one and which version :). I know upgrading is not an easy task but you are recommended to do it anyway.

If upgrading to latest 12.5 version is not an option for you, you would have to contact developer support service for further assistance. 

#196074
Aug 17, 2018 13:11
Vote:
 

I've taken this issue to the developer support. Thank you for your time.

#196125
Aug 20, 2018 8:47
Vote:
 

I was able to look into your site and here's my finding (basically what I sent to developer support)

There was no inventory information attached to the SKU corresponding to the lineitem. When the shipment is cancelled, it is invalidated (so the system can revert reservations made to the the inventory), and the workflow sees that, "ok, no inventory, let's remove the item".

If they want to prevent that behavior you would have too

  • add inventory information for the SKUs. It seems that they have custom implementation of IInventoryService, that custom implementation needs to be in context of Commerce Manager and is registered over the default on.
  • modify the workflows to NOT remove items if there is no inventory information
#196273
Aug 23, 2018 16:29
Vote:
 

It seems if we just add an inventory of 1 to all products, the CommerceManager keeps the order lines for cancelled orders. We're gonna continue with this. Thanks your time and answers!

#196505
Sep 03, 2018 8:28
This topic was created over six months ago and has been resolved. If you have a similar question, please create a new topic and refer to this one.
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.