From a968945057ecb8c63274ada60678f86b20eb3f57 Mon Sep 17 00:00:00 2001 From: Your Name Date: Fri, 7 Aug 2026 15:25:09 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=96=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../logic/firstvisit/FirstVisitDoctorDashboardLogic.php | 2 +- server/app/adminapi/logic/stats/ConversionLogic.php | 2 +- server/app/adminapi/logic/stats/PerformanceDashboardLogic.php | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/server/app/adminapi/logic/firstvisit/FirstVisitDoctorDashboardLogic.php b/server/app/adminapi/logic/firstvisit/FirstVisitDoctorDashboardLogic.php index 77e18d604..8a2d44eaf 100644 --- a/server/app/adminapi/logic/firstvisit/FirstVisitDoctorDashboardLogic.php +++ b/server/app/adminapi/logic/firstvisit/FirstVisitDoctorDashboardLogic.php @@ -392,8 +392,8 @@ class FirstVisitDoctorDashboardLogic ->where('status', 2) ->where('amount', '>', 0) ->where('amount', '<', 10) + // payment_time 是 DATETIME NULL;MySQL 8 严格模式下不能与空字符串比较。 ->whereNotNull('payment_time') - ->where('payment_time', '<>', '') ->whereBetweenTime( 'payment_time', $startDate . ' 00:00:00', diff --git a/server/app/adminapi/logic/stats/ConversionLogic.php b/server/app/adminapi/logic/stats/ConversionLogic.php index cbcf6a429..d5d4b3813 100755 --- a/server/app/adminapi/logic/stats/ConversionLogic.php +++ b/server/app/adminapi/logic/stats/ConversionLogic.php @@ -1088,8 +1088,8 @@ class ConversionLogic ->alias('o') ->whereNull('o.delete_time') ->where('o.status', 2) + // payment_time 是 DATETIME NULL;MySQL 8 严格模式下不能与空字符串比较。 ->whereNotNull('o.payment_time') - ->where('o.payment_time', '<>', '') ->whereBetweenTime('o.payment_time', $startDateTime, $endDateTime) ->fieldRaw('o.creator_id AS source_admin_id, COUNT(*) AS paid_appointment_count') ->group('o.creator_id'); diff --git a/server/app/adminapi/logic/stats/PerformanceDashboardLogic.php b/server/app/adminapi/logic/stats/PerformanceDashboardLogic.php index 5b255a808..564b30426 100644 --- a/server/app/adminapi/logic/stats/PerformanceDashboardLogic.php +++ b/server/app/adminapi/logic/stats/PerformanceDashboardLogic.php @@ -369,8 +369,8 @@ class PerformanceDashboardLogic ->where('status', 2) ->where('amount', '>', 0) ->where('amount', '<', 10) + // payment_time 是 DATETIME NULL;MySQL 8 严格模式下不能与空字符串比较。 ->whereNotNull('payment_time') - ->where('payment_time', '<>', '') ->whereBetweenTime( 'payment_time', $startDate . ' 00:00:00', @@ -501,8 +501,8 @@ class PerformanceDashboardLogic ->where('o.status', 2) ->where('o.amount', '>', 0) ->where('o.amount', '<', 10) + // payment_time 是 DATETIME NULL;MySQL 8 严格模式下不能与空字符串比较。 ->whereNotNull('o.payment_time') - ->where('o.payment_time', '<>', '') ->whereBetweenTime('o.payment_time', date('Y-m-d 00:00:00'), date('Y-m-d 23:59:59')); if ($rankingVisibleAdminIds !== null) { $query->whereIn('o.creator_id', $rankingVisibleAdminIds);