News:

You may pay someone to create your store, or you visit our seminar and become a professional yourself with the silver certification

Main Menu

Coupon Ceases to effect order on backend alteration

Started by wbyers, April 03, 2018, 22:48:07 PM

Previous topic - Next topic

wbyers

 In another Topic I posted
QuoteOkay, so recently we've discovered some add behavior from virtuemart when cancelling line items that coupons have been applied to The total no longer reflects the fact that coupons were used and instead displays the full price they would have paid instead. You can see an example attached to this topic, is there anything that can be done here to ensure that the total still reflects what was actually paid by the consumer for accurate bookkeeping?

This is the specific Issue we are having, when the total is recalculated after a line item cancellation the coupon is not taken into account.  Specifically Something is wrong with the coupon calculation when one is doing a item by item cancel and as a result the coupon is not being applied properly when individual order items have been cancelled. This means if you got a coupon or gift certificate that gave you the whole thing off, cancelling by the item would result in the cert or coupon being reflected in the recalculation on the order total
.I've seen variations of this complaint I've made regarding various alterations to backend orders causing coupons to stop being counted on the forum without any response. Has this been fixed in any newer versions of virtuemart?  I'm using joomla 3.7.2 and virtuemart 3.0.18. According to the AWOdev people this issue is with your system and they tested it on a virtuemart 3.2.13 test site and ran into the same issue using a virtuemart standard coupon system rather than the awocoupon extension for virtuemart.  This problem occurs when an item on the order is cancelled it doesn't even have to be more than one, and that throws off the calculation and causes it to forget the discount in turn resulting in the calculation being for more than the shopper actually billed. Is there anything we or you can do to make sure that we can get it to stop losing the discount when we cancel items on orders or will this have to be done by hand by us? It's odd because the coupon discount is still on record It's just not being applied anymore.

jenkinhill

Kelvyn
Lowestoft, Suffolk, UK

Retired from forum life November 2023

Please mention your VirtueMart, Joomla and PHP versions when asking a question in this forum

aka.deton

#2
del

Milbo

Never heard about that problem. Is new for me.  is on the list now
Should I fix your bug, please support the VirtueMart project and become a member
______________________________________
Extensions approved by the core team: http://extensions.virtuemart.net/

wbyers

Thank you, It's caused on line 653 of the orders.php model under the virtuemart component directory located in administrator. When doing calculating the order_total in the sql the coupon discount is not added when doing individual item updates. 

Milbo

Thank you. Good to know. I know the function, sounds very reasonable.
Should I fix your bug, please support the VirtueMart project and become a member
______________________________________
Extensions approved by the core team: http://extensions.virtuemart.net/

wbyers


Milbo

hmmm not soo easy as I thought before. Coupons use often percentages, so we must recalculate the whole thing, or? We can add/substract the value only, when the coupon was not a percentual one. So maybe it is easier to add a sql, which handles it.
Should I fix your bug, please support the VirtueMart project and become a member
______________________________________
Extensions approved by the core team: http://extensions.virtuemart.net/

wbyers