From f667f5ee4190c10f5cc13e384646fb8c6cd787d7 Mon Sep 17 00:00:00 2001 From: Tokumeikoi Date: Thu, 28 May 2020 23:28:58 +0800 Subject: [PATCH] fix --- app/Services/OrderService.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/Services/OrderService.php b/app/Services/OrderService.php index b7a784ea..d8b53468 100644 --- a/app/Services/OrderService.php +++ b/app/Services/OrderService.php @@ -127,7 +127,7 @@ class OrderService ->where('status', 3); $surplusAmount = 0; foreach ($orderModel->get() as $item) { - $surplusMonth = strtotime("+ {$strToMonth[$item->cycle]}month", $item->updated_at->format('U')); + $surplusMonth = strtotime("+ {$strToMonth[$item->cycle]}month", $item->created_at->format('U')); if (!$surplusMonth) continue; $surplusMonth = ($surplusMonth - time()) / 2678400 / $strToMonth[$item->cycle]; if ($surplusMonth > 0) {