From b63ff58e2c415bae2fb4741aebe710fa3576ff66 Mon Sep 17 00:00:00 2001
From: wjc <1243177876@qq.com>
Date: 星期一, 23 三月 2026 13:11:47 +0800
Subject: [PATCH] 2026年03月23日13:11:38 备份代码

---
 app/src/main/java/com/hdl/photovoltaic/other/HdlResidenceLogic.java |   85 ++++++++----------------------------------
 1 files changed, 17 insertions(+), 68 deletions(-)

diff --git a/app/src/main/java/com/hdl/photovoltaic/other/HdlResidenceLogic.java b/app/src/main/java/com/hdl/photovoltaic/other/HdlResidenceLogic.java
index e816a8f..62d04b3 100644
--- a/app/src/main/java/com/hdl/photovoltaic/other/HdlResidenceLogic.java
+++ b/app/src/main/java/com/hdl/photovoltaic/other/HdlResidenceLogic.java
@@ -253,7 +253,7 @@
                                     houseInfoBean.setInstalledCapacity(houseIdBean.getInstalledCapacity());//瑁呮満瀹归噺
                                     houseInfoBean.setPower(houseIdBean.getPower());//鍙戠數鍔熺巼
                                     houseInfoBean.setTodayElectricity(houseIdBean.getTodayElectricity());//浠婂ぉ鍙戠數閲�
-                                    houseInfoBean.setPowerStationStatus(houseIdBean.getPowerStationStatus());//鐢电珯鐘舵��(鐢电珯鐘舵��	1:姝e父(杩愯),2:绂荤嚎,3:杩炴帴涓�,4:鏁呴殰)
+                                    houseInfoBean.setPowerStationStatus(houseIdBean.getPowerStationStatus());//鐢电珯鐘舵��(鐢电珯鐘舵��    1:姝e父(杩愯),2:绂荤嚎,3:杩炴帴涓�,4:鏁呴殰)
                                     //娣诲姞鍒版湰鍦扮紦瀛�
                                     addHouseToLocalMemory(houseInfoBean);
                                 }
@@ -391,10 +391,11 @@
      * @param installedCapacityMax 鏈�澶х粍涓插閲�(瑁呮満瀹归噺)
      * @param debugStatus          璋冭瘯鐘舵��(鍏ㄩ儴;璋冭瘯涓�;璋冭瘯瀹屾垚;宸蹭氦浠�;鎺堟潈璋冭瘯)
      * @param powerStationStatus   鐢电珯鐘舵�� (鍏ㄩ儴  锛�"";1 锛� 姝e父;2 锛� 绂荤嚎; 3 锛� 寰呮帴鍏�;4 锛� 鏁呴殰)
+     * @param powerStationType     鐢电珯绫诲瀷(INV = 閫嗗彉鍣ㄧ數绔�;BMS = BMS鐢电珯)
      * @param pageNo               椤电爜
      * @param pageSize             椤垫暟锛堜竴椤靛灏戞暟鎹級
      */
-    public void getResidenceIdList(String key, String keyValue, String installedCapacityMin, String installedCapacityMax, String debugStatus, String powerStationStatus, long pageNo, long pageSize, CloudCallBeak<HouseBeanClass> cloudCallBeak) {
+    public void getResidenceIdList(String key, String keyValue, String installedCapacityMin, String installedCapacityMax, String debugStatus, String powerStationStatus, String powerStationType, long pageNo, long pageSize, CloudCallBeak<HouseBeanClass> cloudCallBeak) {
 
         String requestUrl = HttpApi.POST_PowerStation_List;
         JsonObject json = new JsonObject();
@@ -425,6 +426,12 @@
             try {
                 int value = Integer.parseInt(powerStationStatus);
                 json.addProperty("powerStationStatus", value);
+            } catch (Exception ignored) {
+            }
+        }
+        if (!TextUtils.isEmpty(powerStationType)) {
+            try {
+                json.addProperty("powerStationType", powerStationType);
             } catch (Exception ignored) {
             }
         }
@@ -616,8 +623,9 @@
      * @param debugStatus          (璋冭瘯鐘舵��:Debugging = 璋冭瘯涓�,WAIT_DELIVERED = 璋冭瘯瀹屾垚,Delivered = 宸蹭氦浠�,SECONDARY_DEBUGGIN = 鎺堟潈璋冭瘯)
      * @param installedCapacityMin 鏈�灏忕粍涓插閲�(瑁呮満瀹归噺)
      * @param installedCapacityMax 鏈�澶х粍涓插閲�(瑁呮満瀹归噺)
+     * @param powerStationType 鐢电珯绫诲瀷锛堥�嗗彉鍣紝BMS锛�
      */
-    public void getStatusOverview(String debugStatus, String installedCapacityMin, String installedCapacityMax, CloudCallBeak<StatusOverviewBean> cloudCallBeak) {
+    public void getStatusOverview(String debugStatus, String installedCapacityMin, String installedCapacityMax,String powerStationType, CloudCallBeak<StatusOverviewBean> cloudCallBeak) {
         String requestUrl = HttpApi.POST_statusOverview;
         JsonObject json = new JsonObject();
         if (!TextUtils.isEmpty(installedCapacityMin)) {
@@ -628,6 +636,10 @@
         }
         if (!TextUtils.isEmpty(debugStatus)) {
             json.addProperty("debugStatus", debugStatus);
+        }
+
+        if (!TextUtils.isEmpty(powerStationType)) {
+            json.addProperty("powerStationType", powerStationType);
         }
 
 
@@ -934,6 +946,7 @@
 //        HdlFileLogic.getInstance().deleteDirectory(HdlFileLogic.getInstance().getCurrentHomeRootPath());
         //閲嶆柊璁剧疆浣忓畢id
         UserConfigManage.getInstance().setHomeId(houseIdBean.getHomeId());
+        UserConfigManage.getInstance().setPowerStationType(houseIdBean.getPowerStationType());
         UserConfigManage.getInstance().setHomeName(houseIdBean.getHomeName());
         //閲嶆柊璁剧疆鏈湴閫氳绉橀挜
         UserConfigManage.getInstance().setLocalSecret(houseIdBean.getLocalSecret());
@@ -1140,70 +1153,6 @@
 
     }
 
-    /**
-     * 娣诲姞鎺ㄩ�乀oken
-     *
-     * @param cloudCallBeak -
-     */
-    public void pushAdd(CloudCallBeak<String> cloudCallBeak) {
-        String requestUrl = HttpApi.POST_push_add;
-        JsonObject json = new JsonObject();
-        json.addProperty("deviceName", Build.MODEL);//璁惧鍚嶇О
-        json.addProperty("deviceType", "Android");//璁惧绫诲瀷
-        json.addProperty("produce", AppConfigManage.isIsOnlineServer());//琛ㄧず鏄惁鏄寮忔湇鍔″櫒
-        json.addProperty("pushToken", UserConfigManage.getInstance().getRegistrationID());//App鐨勬帹閫乀oken锛屽湪鏋佸厜涓篟egId
-        json.addProperty("software", "PHOTOVOLTAIC");//杞欢鏉ユ簮
-
-        HttpClient.getInstance().requestHttp(requestUrl, json.toString(), new CloudCallBeak<String>() {
-            @Override
-            public void onSuccess(String jsonStr) {
-                if (cloudCallBeak != null) {
-                    cloudCallBeak.onSuccess(jsonStr);
-                }
-
-            }
-
-            @Override
-            public void onFailure(HDLException e) {
-                if (cloudCallBeak != null) {
-                    cloudCallBeak.onFailure(e);
-                }
-            }
-        });
-
-
-    }
-
-    /**
-     * 鍒犻櫎鎺ㄩ�乀oken
-     *
-     * @param cloudCallBeak -
-     */
-    public void pushDel(CloudCallBeak<String> cloudCallBeak) {
-        String requestUrl = HttpApi.POST_push_del;
-        JsonObject json = new JsonObject();
-        json.addProperty("pushId", UserConfigManage.getInstance().getPushId());
-        json.addProperty("pushToken", UserConfigManage.getInstance().getRegistrationID());
-
-        HttpClient.getInstance().requestHttp(requestUrl, json.toString(), new CloudCallBeak<String>() {
-            @Override
-            public void onSuccess(String jsonStr) {
-                if (cloudCallBeak != null) {
-                    cloudCallBeak.onSuccess(jsonStr);
-                }
-
-            }
-
-            @Override
-            public void onFailure(HDLException e) {
-                if (cloudCallBeak != null) {
-                    cloudCallBeak.onFailure(e);
-                }
-            }
-        });
-
-
-    }
 
     public static class HouseBeanClass {
 
@@ -1259,4 +1208,4 @@
         }
     }
 
-}
+}
\ No newline at end of file

--
Gitblit v1.8.0