From f55759bc49b9f487099916b7dee80c0cf4948c78 Mon Sep 17 00:00:00 2001 From: yiqiu Date: Sun, 28 Dec 2025 16:19:41 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E6=8F=92=E4=BB=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../addon/theme_configurator/model/ThemeConfigModel.php | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/plugins/addon/theme_configurator/model/ThemeConfigModel.php b/plugins/addon/theme_configurator/model/ThemeConfigModel.php index 90970d8..b42f39f 100644 --- a/plugins/addon/theme_configurator/model/ThemeConfigModel.php +++ b/plugins/addon/theme_configurator/model/ThemeConfigModel.php @@ -42,7 +42,8 @@ class ThemeConfigModel if ($config !== false && $config !== null) { // 缓存命中 - return $config; + error_log('ThemeConfigModel::getConfig() - 返回banner数: ' . count($config['banner'] ?? [])); + return $config; } } catch (\Throwable $e) { // 缓存系统异常,继续从数据库读取 @@ -51,6 +52,11 @@ class ThemeConfigModel // 缓存未命中,从数据库读取 $row = $this->query()->order('id', 'asc')->find(); + error_log('ThemeConfigModel::getConfig() - 查询结果: ' . ($row ? 'found' : 'not found')); + if ($row) { + error_log('config字段长度: ' . strlen($row['config'])); + error_log('config前100字符: ' . substr($row['config'], 0, 100)); + } if (!$row) { $config = $this->defaultConfig(); } else {