From 8b43d4e1190fc9e2261be0579e53cc6c2987f946 Mon Sep 17 00:00:00 2001
From: wjc <1243177876@qq.com>
Date: 星期四, 27 十一月 2025 19:37:56 +0800
Subject: [PATCH] 2025年11月27日19:37:50 备份代码

---
 app/src/main/java/com/hdl/photovoltaic/other/HdlFileLogic.java |   66 ++++++++++++++++++++++++++-------
 1 files changed, 52 insertions(+), 14 deletions(-)

diff --git a/app/src/main/java/com/hdl/photovoltaic/other/HdlFileLogic.java b/app/src/main/java/com/hdl/photovoltaic/other/HdlFileLogic.java
index c3065ba..e2d525d 100644
--- a/app/src/main/java/com/hdl/photovoltaic/other/HdlFileLogic.java
+++ b/app/src/main/java/com/hdl/photovoltaic/other/HdlFileLogic.java
@@ -10,6 +10,7 @@
 import com.hdl.photovoltaic.HDLApp;
 import com.hdl.photovoltaic.config.ConstantManage;
 import com.hdl.photovoltaic.config.UserConfigManage;
+import com.hdl.photovoltaic.enums.Languages;
 import com.hdl.photovoltaic.utils.LocalManageUtil;
 
 import org.apache.commons.io.FileUtils;
@@ -103,16 +104,20 @@
 
     /**
      * 鑾峰彇涓枃銆恓son璧勬簮鏂囦欢澶广�戝叏璺緞
+     *
+     * @param deviceModel 璁惧鍨嬪彿
      */
     public String getHdlESLocalJsonZhRootPath(String deviceModel) {
-        return getAPPInternalStoreFilesPath() + "/hdlESLocalJson/" + LocalManageUtil.zh + "/" + deviceModel;
+        return getAPPInternalStoreFilesPath() + "/hdlESLocalJson/" + Languages.zh + "/" + deviceModel;
     }
 
     /**
      * 鑾峰彇鑻辨枃銆恓son璧勬簮鏂囦欢澶广�戝叏璺緞
+     *
+     * @param deviceModel 璁惧鍨嬪彿
      */
     public String getHdlESLocalJsonEnRootPath(String deviceModel) {
-        return getAPPInternalStoreFilesPath() + "/hdlESLocalJson/" + LocalManageUtil.en + "/" + deviceModel;
+        return getAPPInternalStoreFilesPath() + "/hdlESLocalJson/" + Languages.en + "/" + deviceModel;
     }
 
 
@@ -138,7 +143,7 @@
         if (!fileName.endsWith(".json")) {
             fileName += ".json";
         }
-        return getAPPInternalStoreFilesPath() + "/hdlESLocalJson/" + LocalManageUtil.zh + "/" + deviceModel + "/" + fileName;
+        return getAPPInternalStoreFilesPath() + "/hdlESLocalJson/" + Languages.zh + "/" + deviceModel + "/" + fileName;
     }
 
     /**
@@ -148,7 +153,7 @@
         if (!fileName.endsWith(".json")) {
             fileName += ".json";
         }
-        return getAPPInternalStoreFilesPath() + "/hdlESLocalJson/" + LocalManageUtil.en + "/" + deviceModel + "/" + fileName;
+        return getAPPInternalStoreFilesPath() + "/hdlESLocalJson/" + Languages.en + "/" + deviceModel + "/" + fileName;
     }
 
 
@@ -190,7 +195,6 @@
         this.createFileDir(this.getDriveRootPath());
         //鍥轰欢鏂囦欢
         this.createFileDir(this.getFirmwareRootPath());
-
     }
 
     /**
@@ -198,16 +202,50 @@
      */
     public void createHdlESLocalJsonDirectory() {
         //涓枃鏂囦欢澶�
-        this.createFileDir(this.getHdlESLocalJsonZhRootPath(HdlESLocalJsonLogic.deviceModel_ME_GSE_S5K));//閫嗗彉鍣�
-        this.createFileDir(this.getHdlESLocalJsonZhRootPath(HdlESLocalJsonLogic.deviceModel_ME_GSE_SPG63A));//璐熻浇涓績
-        this.createFileDir(this.getHdlESLocalJsonZhRootPath(HdlESLocalJsonLogic.deviceModel_ME_GSE_BMS15K));//BMS
-        this.createFileDir(this.getHdlESLocalJsonZhRootPath(HdlESLocalJsonLogic.deviceModel_ME_GSE_B5K));//鐢垫睜鍖�
-        //鑻辨枃鏂囦欢澶�
-        this.createFileDir(this.getHdlESLocalJsonEnRootPath(HdlESLocalJsonLogic.deviceModel_ME_GSE_S5K));
-        this.createFileDir(this.getHdlESLocalJsonEnRootPath(HdlESLocalJsonLogic.deviceModel_ME_GSE_SPG63A));
-        this.createFileDir(this.getHdlESLocalJsonEnRootPath(HdlESLocalJsonLogic.deviceModel_ME_GSE_BMS15K));
-        this.createFileDir(this.getHdlESLocalJsonEnRootPath(HdlESLocalJsonLogic.deviceModel_ME_GSE_B5K));
+        //骞剁綉-閫嗗彉鍣�
+        this.createFileDir(this.getHdlESLocalJsonZhRootPath(HdlESLocalJsonLogic.DeviceModel.INV));//骞剁綉-閫嗗彉鍣�
+        this.createFileDir(this.getHdlESLocalJsonZhRootPath(HdlESLocalJsonLogic.DeviceModel.LC));//璐熻浇涓績
+        this.createFileDir(this.getHdlESLocalJsonZhRootPath(HdlESLocalJsonLogic.DeviceModel.INV_BMS));//BMS
+        this.createFileDir(this.getHdlESLocalJsonZhRootPath(HdlESLocalJsonLogic.DeviceModel.INV_BATTERY));//鐢垫睜鍖�
+        //绂荤嚎-閫嗗彉鍣�
+        this.createFileDir(this.getHdlESLocalJsonZhRootPath(HdlESLocalJsonLogic.DeviceModel.OFF_INV));//绂荤嚎-閫嗗彉鍣�
+        this.createFileDir(this.getHdlESLocalJsonZhRootPath(HdlESLocalJsonLogic.DeviceModel.OFF_INV_BMS));//绂荤綉-閫嗗彉鍣�-铏氭嫙BMS
+        this.createFileDir(this.getHdlESLocalJsonZhRootPath(HdlESLocalJsonLogic.DeviceModel.OFF_INV_BATTERY));//绂荤綉-閫嗗彉鍣�-鐢垫睜鍖�
 
+        //绂荤嚎-3.6kw閫嗗彉鍣�
+        this.createFileDir(this.getHdlESLocalJsonZhRootPath(HdlESLocalJsonLogic.DeviceModel.OFF_INV_3));//绂荤嚎-閫嗗彉鍣�3.6kw
+        this.createFileDir(this.getHdlESLocalJsonZhRootPath(HdlESLocalJsonLogic.DeviceModel.OFF_INV_BMS_3));//绂荤綉-閫嗗彉鍣�-铏氭嫙BMS
+         //鐢垫睜鍖呰浆鎹㈠櫒
+        this.createFileDir(this.getHdlESLocalJsonZhRootPath(HdlESLocalJsonLogic.DeviceModel.INV_KE_GLE_B5K_BATTERY));//鐢垫睜鍖呰浆鎹㈠櫒
+
+        //绂荤嚎-7.6kw閫嗗彉鍣�
+        this.createFileDir(this.getHdlESLocalJsonZhRootPath(HdlESLocalJsonLogic.DeviceModel.OFF_INV_7));//绂荤嚎-閫嗗彉鍣�7.6kw
+        this.createFileDir(this.getHdlESLocalJsonZhRootPath(HdlESLocalJsonLogic.DeviceModel.OFF_INV_BMS_7));//绂荤綉-閫嗗彉鍣�-BMS
+        this.createFileDir(this.getHdlESLocalJsonZhRootPath(HdlESLocalJsonLogic.DeviceModel.INV_KE_GLE_B15K_BATTERY));//绂荤綉-閫嗗彉鍣�-鐢垫睜鍖�15k
+
+
+
+        //鑻辨枃鏂囦欢澶�
+        this.createFileDir(this.getHdlESLocalJsonEnRootPath(HdlESLocalJsonLogic.DeviceModel.INV));
+        this.createFileDir(this.getHdlESLocalJsonEnRootPath(HdlESLocalJsonLogic.DeviceModel.LC));
+        this.createFileDir(this.getHdlESLocalJsonEnRootPath(HdlESLocalJsonLogic.DeviceModel.INV_BMS));
+        this.createFileDir(this.getHdlESLocalJsonEnRootPath(HdlESLocalJsonLogic.DeviceModel.INV_BATTERY));
+        //绂荤嚎閫嗗彉鍣�
+        this.createFileDir(this.getHdlESLocalJsonEnRootPath(HdlESLocalJsonLogic.DeviceModel.OFF_INV));//绂荤嚎-閫嗗彉鍣�
+        this.createFileDir(this.getHdlESLocalJsonEnRootPath(HdlESLocalJsonLogic.DeviceModel.OFF_INV_BMS));//绂荤綉-閫嗗彉鍣�-铏氭嫙BMS
+        this.createFileDir(this.getHdlESLocalJsonEnRootPath(HdlESLocalJsonLogic.DeviceModel.OFF_INV_BATTERY));//绂荤綉-閫嗗彉鍣�-鐢垫睜鍖�
+
+        //绂荤嚎-3.6kw閫嗗彉鍣�
+        this.createFileDir(this.getHdlESLocalJsonEnRootPath(HdlESLocalJsonLogic.DeviceModel.OFF_INV_3));//绂荤嚎-閫嗗彉鍣�
+        this.createFileDir(this.getHdlESLocalJsonEnRootPath(HdlESLocalJsonLogic.DeviceModel.OFF_INV_BMS_3));//绂荤綉-閫嗗彉鍣�-铏氭嫙BMS
+
+        //鐢垫睜鍖呰浆鎹㈠櫒
+        this.createFileDir(this.getHdlESLocalJsonEnRootPath(HdlESLocalJsonLogic.DeviceModel.INV_KE_GLE_B5K_BATTERY));//鐢垫睜鍖呰浆鎹㈠櫒
+
+        //绂荤嚎-7.6kw閫嗗彉鍣�
+        this.createFileDir(this.getHdlESLocalJsonEnRootPath(HdlESLocalJsonLogic.DeviceModel.OFF_INV_7));//绂荤嚎-閫嗗彉鍣�7.6kw
+        this.createFileDir(this.getHdlESLocalJsonEnRootPath(HdlESLocalJsonLogic.DeviceModel.OFF_INV_BMS_7));//绂荤綉-閫嗗彉鍣�-BMS
+        this.createFileDir(this.getHdlESLocalJsonEnRootPath(HdlESLocalJsonLogic.DeviceModel.INV_KE_GLE_B15K_BATTERY));//绂荤綉-閫嗗彉鍣�-鐢垫睜鍖�15k
     }
 
     /**

--
Gitblit v1.8.0