WooCommerce.NET icon indicating copy to clipboard operation
WooCommerce.NET copied to clipboard

Coupon lines in orders, 'discount' and 'discount_tax' are null

Open kevinamorim opened this issue 4 years ago • 2 comments

Make sure you have included the below details when open an issue. Thank you.

When getting an order with coupons, the coupon lines have the 'discount' and 'discount_tax' as null.

This happens because the value is being assigned to 'discountValue' and discount_taxValue' fields, both protected.

I don't know if there is a good reason for this to happen, but since they are protected, I cannot use them.

**Wordpress Version: ** 5.5.3 **WooCommerce.NET Version: ** 0.8.2

kevinamorim avatar Nov 17 '20 16:11 kevinamorim

In version 0.8.3 from NuGet this is still an issue.

NickDomanti avatar Nov 11 '21 14:11 NickDomanti

+1

gkverneland avatar Jan 20 '22 09:01 gkverneland

It's still an issue

danieledignani avatar Nov 28 '23 16:11 danieledignani

It's still an issue. Always discount and discount_tax are null. And the 'discountValue' and discount_taxValue' fields are protected. How can I get the value of the coupon to display it? Please Someone have another idea to get discount's value from the coupon?

KaoutharG avatar Jan 02 '24 15:01 KaoutharG