Fixed a bug with recurring subscriptions

This commit is contained in:
sluther
2009-10-01 16:35:52 -07:00
parent a2034bfb7b
commit 7e8ee8bc5a
3 changed files with 9 additions and 9 deletions

View File

@@ -77,9 +77,9 @@ class plg_chout_PAYPAL_RECURRING extends base_checkout_plugin
if($recurr_bill_arr[0]["recurr_type"] == "1")
{
# Pro-rate billing:
include_once ( PATH_MODULES . 'checkout/checkout.inc.php' );
$checkout = new checkout;
$arr = $checkout->recurrDates($recurr_bill_arr[0]["recurr_schedule"], $recurr_bill_arr[0]["recurr_weekday"], $recurr_bill_arr[0]["recurr_week"]);
include_once ( PATH_MODULES . 'product/product.inc.php' );
$product = new product;
$arr = $product->recurrDates($recurr_bill_arr[0]["recurr_schedule"], $recurr_bill_arr[0]["recurr_weekday"], $recurr_bill_arr[0]["recurr_week"]);
$remain_time = $arr['end'] - time();
$period1 = round($remain_time/86400);
$subscr_date = date("Y-m-d", $arr["end"]);