candy-api icon indicating copy to clipboard operation
candy-api copied to clipboard

Fix issues in discount

Open ahmad753 opened this issue 6 years ago • 2 comments

ahmad753 avatar May 24 '19 00:05 ahmad753

Hi @ahmad753 I'm not sure this fixes anything, can you explain more what you're trying to solve?

alecritson avatar Jun 07 '19 15:06 alecritson

@alecritson This commit "Fix basket line reward apply" $reward->type the type is return like this "percentage_amount,fixed_amount or to_fixed_price" and after using $method = 'apply'.ucfirst($reward->type); it just appends "apply" then convert the first character to uppercase, and when checking the method exist it will return false, because the method variable value is applyPercentage_amout for i.e. which not exist.

And for this commit "Fix issues in discount" the removed line its not functioning, so I increment the discount from its set.

ahmad753 avatar Jun 07 '19 15:06 ahmad753