From 1fc2de058a8746fc842be1f9a77a45c3dcd81a4e Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E5=B0=8F=E8=83=A1?= <3203164629@qq.com>
Date: Fri, 26 Jul 2024 11:43:40 +0800
Subject: [PATCH] =?UTF-8?q?=E7=B3=BB=E7=BB=9F=E8=AE=BE=E7=BD=AE=E4=B8=AD?=
=?UTF-8?q?=E5=A2=9E=E5=8A=A0=E6=8A=A5=E9=94=99=E6=8F=90=E7=A4=BA=E5=85=B3?=
=?UTF-8?q?=E9=97=AD=E9=80=89=E9=A1=B9?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
admin/setting/template/main.htm | 16 ++++++++++++++++
core/template/default/common/footer.htm | 7 +++++--
core/template/default/common/footer_simple.htm | 7 +++++--
core/template/default/common/footer_system.htm | 7 +++++--
4 files changed, 31 insertions(+), 6 deletions(-)
diff --git a/admin/setting/template/main.htm b/admin/setting/template/main.htm
index 91cfad9..ffc4665 100644
--- a/admin/setting/template/main.htm
+++ b/admin/setting/template/main.htm
@@ -536,6 +536,22 @@
+
+
+
+
+ checked="checked" >
+
+
+
+ checked="checked">
+
+
+
+
+
diff --git a/core/template/default/common/footer.htm b/core/template/default/common/footer.htm
index 44434ad..67e8f80 100644
--- a/core/template/default/common/footer.htm
+++ b/core/template/default/common/footer.htm
@@ -142,12 +142,14 @@ $_G['setting']['statcode']
showmessage(errorMsg, 'error', 3000, 1);
}
});
- // 保持原有的错误监听器
+
+
window.addEventListener('error', function(event) {
handleErrors(event);
}, true);
+
});
-
+
function handleErrors(event) {
try {
// 检查是否存在错误对象
@@ -167,6 +169,7 @@ $_G['setting']['statcode']
console.error("Failed to report or show error:", error);
}
}
+
diff --git a/core/template/default/common/footer_simple.htm b/core/template/default/common/footer_simple.htm
index 65d29b5..bb7ec93 100644
--- a/core/template/default/common/footer_simple.htm
+++ b/core/template/default/common/footer_simple.htm
@@ -148,12 +148,14 @@ try{
showmessage(errorMsg, 'error', 3000, 1);
}
});
- // 保持原有的错误监听器
+
+
window.addEventListener('error', function(event) {
handleErrors(event);
}, true);
+
});
-
+
function handleErrors(event) {
try {
// 检查是否存在错误对象
@@ -173,6 +175,7 @@ try{
console.error("Failed to report or show error:", error);
}
}
+
diff --git a/core/template/default/common/footer_system.htm b/core/template/default/common/footer_system.htm
index 19e11c0..6892218 100644
--- a/core/template/default/common/footer_system.htm
+++ b/core/template/default/common/footer_system.htm
@@ -28,12 +28,14 @@ try{
showmessage(errorMsg, 'error', 3000, 1);
}
});
- // 保持原有的错误监听器
+
+
window.addEventListener('error', function(event) {
handleErrors(event);
}, true);
+
});
-
+
function handleErrors(event) {
try {
// 检查是否存在错误对象
@@ -53,6 +55,7 @@ try{
console.error("Failed to report or show error:", error);
}
}
+