From 8814f3f0828e6ac652a29cc9de9f971fd55bca5b Mon Sep 17 00:00:00 2001
From: wjc <1243177876@qq.com>
Date: 星期三, 07 五月 2025 14:54:42 +0800
Subject: [PATCH] 2025年05月07日14:54:39

---
 app/src/main/java/com/hdl/photovoltaic/other/HdlLogLogic.java |   11 ++++++-----
 1 files changed, 6 insertions(+), 5 deletions(-)

diff --git a/app/src/main/java/com/hdl/photovoltaic/other/HdlLogLogic.java b/app/src/main/java/com/hdl/photovoltaic/other/HdlLogLogic.java
index 357d044..dab21db 100644
--- a/app/src/main/java/com/hdl/photovoltaic/other/HdlLogLogic.java
+++ b/app/src/main/java/com/hdl/photovoltaic/other/HdlLogLogic.java
@@ -16,10 +16,10 @@
     public static boolean isStartPrintLogcat = true;
 
     //鏄惁鍚姩鍔犲埌鍐呭瓨閲岄潰鐨勬爣绛�(true:琛ㄧず鍔犲叆锛宖alse锛氳〃绀轰笉鍔犲叆)
-    public static boolean isStartAddToMemory = false;
+    public static boolean isStartAddToMemory = true;
 
     //榛樿鎵撳嵃鏍囬
-    private static String logTitle = "鑷畾涔夎緭鍑烘墦鍗颁俊鎭�";
+    private static String logTitle = "";//鑷畾涔夎緭鍑烘墦鍗颁俊鎭�
 
     private static final Gson gson = new Gson();
 
@@ -71,7 +71,7 @@
             customLogObject.setCode(code);
             String json = logTitle + (UserConfigManage.getInstance().isBAccount() ? "(B绔�)==" : "(C绔�)==") + gson.toJson(customLogObject);
             if (isStartPrintLogcat) {
-                System.out.println(json);
+                System.out.println(json.replace("\\", ""));
             }
             if (isStartAddToMemory) {
                 if (isAddToMemory) {
@@ -90,8 +90,9 @@
      */
     public static void writeLog(String strLog) {
         synchronized (HdlLogLogic.class) {
-            strLog = TimeUtils.getTimeFromTimestamp(System.currentTimeMillis()) + "s%" + " " + strLog;//鍔犳墦鍗版椂闂�(s%鍗犱綅绗︼紝璁剧疆鏄剧ず鏃堕棿涓嶅悓瀛椾綋棰滆壊)
-            HdlFileLogic.getInstance().appendFile(HdlFileLogic.getInstance().getLogFileNamePath(), strLog);
+            strLog = TimeUtils.getTimeFromTimestamp(System.currentTimeMillis(), true) + "s%" + " " + strLog;//鍔犳墦鍗版椂闂�(s%鍗犱綅绗︼紝璁剧疆鏄剧ず鏃堕棿涓嶅悓瀛椾綋棰滆壊)
+
+            HdlFileLogic.getInstance().appendFile(HdlFileLogic.getInstance().getLogFileNamePath(), strLog.replace("\\", ""));
         }
     }
 

--
Gitblit v1.8.0