The no_discount feature is not being checked properly and all products will receive a discount if a role discount applies.

The issue seems to be that product_specials_get() in product.inc always applies the discount.

CommentFileSizeAuthor
#2 product.inc2_.diff270 bytesmbennett
#1 product.inc_.diff131 bytesmbennett

Comments

mbennett’s picture

Status: Active » Reviewed & tested by the community
StatusFileSize
new131 bytes

No discount was broken due to a typo in product.inc. no_discount had an 's' on the end which meant it didn't match.

The line:
if (!(product_attributes_get($node, 'no_discounts'))) {
Should be:
if (!(product_attributes_get($node, 'no_discount'))) {

mbennett’s picture

StatusFileSize
new270 bytes

The patch has been updated so that another bug in the same function (product_specials_get) is fixed.

$total = 0 should be returned if no discounts exist.