From bfae910688e671266964a904028b5b6b585861ab Mon Sep 17 00:00:00 2001 From: hellcat <> Date: Fri, 4 Apr 2025 17:50:12 +0800 Subject: [PATCH] no message --- src/Services/Cron.php | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/Services/Cron.php b/src/Services/Cron.php index 77431bac..0e874a84 100755 --- a/src/Services/Cron.php +++ b/src/Services/Cron.php @@ -657,12 +657,18 @@ final class Cron $targetDate = new DateTime($oZhuanfasRow->end_date); $interval = $today->diff($targetDate); + if ($today > $targetDate) { + $iDiffDay = -$interval->days; + } else { + $iDiffDay = $interval->days; + } + $oTgSendFormat->rowAdd( $oZhuanfasRow->name, $oZhuanfasRow->today_width, $oZhuanfasRow->use_width, $oZhuanfasRow->max_width, - $interval->days + $iDiffDay ); }