Developer forum

Forum » Development » Split orderlines

Split orderlines

Martin Grønbekk Moen
Martin Grønbekk Moen
Reply

What is the fastest most reliable way to split one orderline into multiple orderlines?

Ex.
2 x PROD1

Shall become
1 x PROD1
1 x PROD1

By default when you buy more than one of one product it is merged, and that is good.
But we have a scenario where we have custom orderline fields that needs to be filled out seperatly on each instance of the product.
So when you buy 2 of the same product we are now stuck with only having the possibility to write the same information on both products, but we need to be able to write two separate lines of information.

Are there any nice ways to solve this?  


Replies

 
Adrian Ursu Dynamicweb Employee
Adrian Ursu
Reply
This post has been marked as an answer

Hi Martin,

Usually, if you have a Custom Orderline Field with different values per orderline, even if it is the same product, it will be stored as separate orderline.

We used a custom orderline field in which we stored the timestamp. This way everytime the product is added, the value is different and the orderlines are not merged.

I hope this approach still works.

Adrian

Votes for this answer: 1
 
Martin Grønbekk Moen
Martin Grønbekk Moen
Reply

Thanks Adrian, I will give it a go :)

 

You must be logged in to post in the forum