Developer forum

Forum » Dynamicweb 10 » Voucher as Product Discount

Voucher as Product Discount

Kenneth Holm
Reply

Hi,

 

Using 10.14.1

When adding a percentage campaign using a Voucher, Checkout reports that it cannot find the voucher (Both using VoucherList and Voucher Order Field). This is when setting the discount to a "Product Discount".

 

However setting the Discount Type to "Order Discount", it works fine.

Using 10.8.1

This works flawlessly (Might work in later versions too, haven't tested). Both with Order and Product Discount.

 

Haven't had time to debug any deeper. - Tested on a clean solution with Swift 1.26.6

 

Best Regards

Kenneth Holm

 


Replies

 
Merethe Vrå Andersen Dynamicweb Employee
Merethe Vrå Andersen
Reply

Hi, 

I can't reproduce that. I use Swift version 1.26.8 and DW 10.15

Product voucher:
https://dynamicweb-my.sharepoint.com/:v:/g/personal/mni_dynamicweb_dk/EdToI4zh_DJJiNV1SjeOaiUBM4_9uZpuyx5yVV1M8JHgXw

Order voucher:
https://dynamicweb-my.sharepoint.com/:v:/g/personal/mni_dynamicweb_dk/ETT6mJWz5OxJgL6LZwQ3LO8BvLezdBXC5yhHVWritWq5SQ 

Do you have a specific setup in the other discount settings? Or maybe try with latest Swift and DW10.

Kind regards,
Merethe Vrå Andersen

 
Kenneth Holm
Reply

Hi Merethe,

 

I've done some more testing across versions, with a very straight forward discount setup.

I can confirm it's not working on 10.14.2 either (Obviously I could be doing something wrong). I guess there is a fix in 10.15 which is not released yet, that's fixing this.

I'll re-test when 10.15 is out and return if needed. Thanks a lot for the help :)

 

/Kenneth

 
Kenneth Holm
Reply
 
Kenneth Holm
Reply

Hi Merete,

 

I've done some more testing, on 10.15 and 10.15.3

It seems to be a DW bug. The internal API call seems to be returning null: Dynamicweb.Ecommerce.Services.Vouchers.GetVoucherByCode(code) 

This only happens when the configuration is set to "Product Discount". It works fine with "Order Discount":

 

I think your test scenario is slightly tainted. Looking through the video it seems like you have 2 running discount campaigns with the same voucher, creating a tainted test scenario. My reasoning for thinking this, is that the configuration you show in the video, the Campaign name, does not match with the campaign name showing up in the cart summary. See my snippets.

 

 
Nicolai Pedersen Dynamicweb Employee
Nicolai Pedersen
Reply
This post has been marked as an answer

Hi Kenneth

It has later been reproduced and is to be found here: https://doc.dynamicweb.dev/documentation/fundamentals/dw10release/releasenotes/workiteminfo.html?workitemid=24210

Votes for this answer: 1
 
Kenneth Holm
Reply

Hi NP,

 

Thanks a lot for the status. However the task suggests you are removing the configuration options, and not fixing the 'bug.

Fair play if that's the strategy, however I just tested it in DW 9.19.2 - And there it works fine applying vouchers through a Product discount.

I give you that it makes more sense as an order discount, but we usually try to mimic the discount models after what the customers are doing in their ERP, to avoid a lot of complexity in the integration. Having this option definately saves some integration hours in some projects, so please don't remove it unless you really have to :)

 

/Kenneth

 
Nicolai Pedersen Dynamicweb Employee
Nicolai Pedersen
Reply

Hi Kenneth

We will fix the bug - apparantly we have a number of different work items related to this one - but we will figure it out.

And no, it makes no sense to have a product discount with an order voucher. In general vouchers do not make sense at all :-).

 

You must be logged in to post in the forum