From 3d7c6fbd1e685720ce60fcf81fd71b7b69c57006 Mon Sep 17 00:00:00 2001 From: songchenxuan Date: Tue, 27 Jun 2023 10:11:08 +0800 Subject: [PATCH] * Fix dashboard update bug. --- module/upgrade/model.php | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/module/upgrade/model.php b/module/upgrade/model.php index b6929f023e..95f9799660 100644 --- a/module/upgrade/model.php +++ b/module/upgrade/model.php @@ -8514,6 +8514,13 @@ class upgradeModel extends model if($chart) { + if($chart->sql) + { + $this->dbh->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_SILENT); + $stmt = $this->dbh->query($chart->sql); + if(!$stmt) continue; + } + $settings = $chart->settings; if($type == 'chart') $chartType = $chart->builtin ? $chart->type : $settings[0]['type']; if($type == 'pivot') $chartType = 'table';