From 0201ca4050a9df81ba7c9d091c0737319182a1ce Mon Sep 17 00:00:00 2001 From: qixinzhi Date: Mon, 17 Apr 2023 05:18:46 +0000 Subject: [PATCH] * Fix where condition sql with key words. --- module/chart/model.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/module/chart/model.php b/module/chart/model.php index 74bc1cb709..b193129840 100644 --- a/module/chart/model.php +++ b/module/chart/model.php @@ -538,7 +538,7 @@ class chartModel extends model $wheres = array(); foreach($filters as $field => $filter) { - $wheres[] = "$field {$filter['operator']} {$filter['value']}"; + $wheres[] = "`$field` {$filter['operator']} {$filter['value']}"; } $whereStr = implode(' and ', $wheres);