broken coupons in vm3.2.6 (not OPC related !)

If you are runnig Joomla 3.x and Virtuemart 3.x please post to this forum your questions or support tickets about One Page Checkout

broken coupons in vm3.2.6 (not OPC related !)

Postby admin » Fri Nov 24, 2017 11:22 pm

the vm3.2.6 includes an error where you cannot create a new coupon code.

to fix the problem you may want to edit:
\administrator\components\com_virtuemart\views\coupon\view.html.php

find this line (should be line 92):
Code: Select all
$coupon->coupon_expiry_date = $_expDate->format("U");


and replace with:
Code: Select all
$coupon->coupon_expiry_date = $_expDate->format("Y-m-d H:i:s");


best regards, stan
admin
Site Admin
 
Posts: 2708
Joined: Wed Jan 06, 2010 11:43 pm

Re: broken coupons in vm3.2.6 (not OPC related !)

Postby admin » Wed Nov 29, 2017 2:09 pm

to get the coupon expirity always to the midnight you may want to use:
Code: Select all
$coupon->coupon_expiry_date = $_expDate->format("Y-m-d");


which should be still a valid date for the purpose (not tested).

best regards, stan
admin
Site Admin
 
Posts: 2708
Joined: Wed Jan 06, 2010 11:43 pm


Return to One Page Checkout for Virtuemart 3 on Joomla 3.x

cron