From 661fe3a7bf3a4c4f4200106540982268b260b4a1 Mon Sep 17 00:00:00 2001
From: mac <user@users-MacBook-Pro.local>
Date: 星期四, 24 十月 2024 11:58:00 +0800
Subject: [PATCH] 2024年10月24日11:57:42

---
 app/src/main/java/com/hdl/photovoltaic/other/HdlUniLogic.java |   41 +++++++++++++++++++++++++++++------------
 1 files changed, 29 insertions(+), 12 deletions(-)

diff --git a/app/src/main/java/com/hdl/photovoltaic/other/HdlUniLogic.java b/app/src/main/java/com/hdl/photovoltaic/other/HdlUniLogic.java
index 5a804ba..768cb99 100644
--- a/app/src/main/java/com/hdl/photovoltaic/other/HdlUniLogic.java
+++ b/app/src/main/java/com/hdl/photovoltaic/other/HdlUniLogic.java
@@ -180,10 +180,7 @@
                     case HDLUniMP.UNI_EVENT_REPLY_HOME_ADD: {
                         String url = getKeyValue("url", getKeyValue("data", data));
                         //EventBus浜嬩欢鍒嗗彂
-                        HdlCommonLogic.getInstance().postEventBusSticky(
-                                HDLUniMP.UNI_EVENT_REPLY_HOME_ADD,
-                                HDLUniMP.UNI_EVENT_REPLY_HOME_ADD,
-                                url);
+                        HdlCommonLogic.getInstance().postEventBusSticky(HDLUniMP.UNI_EVENT_REPLY_HOME_ADD, HDLUniMP.UNI_EVENT_REPLY_HOME_ADD, url);
 
                         if (callback != null) {
                             uniSuccessCallback(type, null, callback);
@@ -200,10 +197,7 @@
                     //鍒涘缓鐢电珯
                     case HDLUniMP.UNI_EVENT_REPLY_HOME_CREATION: {
                         //EventBus浜嬩欢鍒嗗彂
-                        HdlCommonLogic.getInstance().postEventBus(
-                                HDLUniMP.UNI_EVENT_REPLY_HOME_MODEL,
-                                HDLUniMP.UNI_EVENT_REPLY_HOME_CREATION,
-                                getKeyValue("data", data));
+                        HdlCommonLogic.getInstance().postEventBus(HDLUniMP.UNI_EVENT_REPLY_HOME_MODEL, HDLUniMP.UNI_EVENT_REPLY_HOME_CREATION, getKeyValue("data", data));
                         if (callback != null) {
                             uniSuccessCallback(type, null, callback);
                         }
@@ -238,10 +232,7 @@
                     //浣忓畢銆愮數绔欍�戠紪杈�
                     case HDLUniMP.UNI_EVENT_REPLY_HOME_EDIT: {
                         //EventBus浜嬩欢鍒嗗彂
-                        HdlCommonLogic.getInstance().postEventBus(
-                                HDLUniMP.UNI_EVENT_REPLY_HOME_MODEL,
-                                HDLUniMP.UNI_EVENT_REPLY_HOME_EDIT,
-                                getKeyValue("data", data));
+                        HdlCommonLogic.getInstance().postEventBus(HDLUniMP.UNI_EVENT_REPLY_HOME_MODEL, HDLUniMP.UNI_EVENT_REPLY_HOME_EDIT, getKeyValue("data", data));
                         if (callback != null) {
                             uniSuccessCallback(type, null, callback);
                         }
@@ -696,6 +687,32 @@
 
                     }
                     break;
+                    //link杩涜瀵嗙爜楠岃瘉
+                    case HDLUniMP.UNI_EVENT_REPLY_OTHER_Password_verifiy: {
+                        String password = getKeyValue("password", getKeyValue("data", data));
+                        String mac = getKeyValue("mac", getKeyValue("data", data));
+
+                        String requestUrl = TopicApi.DELETING_GATEWAY_password_verifiy;
+                        JsonObject json = new JsonObject();
+                        json.addProperty("password", password);
+                        json.addProperty("mac", mac);
+                        TcpClient.getInstance().sendDataToLinkGateway(mac, true, requestUrl, json, "", new HDLLinkCallBack() {
+                            @Override
+                            public void onSuccess(String msg) {
+                                if (callback != null) {
+                                    uniSuccessCallback(type, msg, callback);
+                                }
+                            }
+
+                            @Override
+                            public void onError(HDLLinkException e) {
+                                if (callback != null) {
+                                    uniCallbackData(type, null, e.getCode(), e.getMsg(), callback);
+                                }
+                            }
+                        });
+                    }
+                    break;
                 }
             }
 

--
Gitblit v1.8.0