From 0287b5d20f7d57f5352248175733b99d5a99959b Mon Sep 17 00:00:00 2001 From: wjc <1243177876@qq.com> Date: 星期四, 28 八月 2025 17:42:27 +0800 Subject: [PATCH] Merge branch '1.4.4' into dev --- app/src/main/java/com/hdl/photovoltaic/ui/powerstation/HouseAndDeviceFragment.java | 41 +++++++++++++++++++++++++---------------- 1 files changed, 25 insertions(+), 16 deletions(-) diff --git a/app/src/main/java/com/hdl/photovoltaic/ui/powerstation/HouseAndDeviceFragment.java b/app/src/main/java/com/hdl/photovoltaic/ui/powerstation/HouseAndDeviceFragment.java index 5e2d0cc..74d905b 100644 --- a/app/src/main/java/com/hdl/photovoltaic/ui/powerstation/HouseAndDeviceFragment.java +++ b/app/src/main/java/com/hdl/photovoltaic/ui/powerstation/HouseAndDeviceFragment.java @@ -346,8 +346,11 @@ houseIdBean.setDebugStatus(DebugStatus.Debugging); HdlResidenceLogic.getInstance().updateHouseIdBean(houseIdBean); initData(); + if (houseInfoAdapter != null) { + houseInfoAdapter.setList(houseListBeanIDList, powerStationStatusValue);//閲嶆柊鍒锋柊鍒楄〃 + } //鏇存柊UI - houseInfoAdapter.notifyItemChanged(position); +// houseInfoAdapter.notifyItemChanged(position); } } @@ -358,20 +361,26 @@ }); } else { showLoading(getString(R.string.deleting_please_wait)); - HdlDeviceLogic.getInstance().getCurrentHomeLocalAndCloudGatewayList(houseIdBean.getHomeId(), new CloudCallBeak<List<GatewayBean>>() { - @Override - public void onSuccess(List<GatewayBean> list) { - //鍙戣捣鍒犻櫎鐢电珯鎸囦护 - deleteResidence(position, houseIdBean, list); + if (houseIdBean.getDebugType().equals(DebugType.NORMAL)) { + //銆愬父瑙勬柟寮忋�戝彂璧峰垹闄ょ數绔欐寚浠� + HdlDeviceLogic.getInstance().getCurrentHomeLocalAndCloudGatewayList(houseIdBean.getHomeId(), new CloudCallBeak<List<GatewayBean>>() { + @Override + public void onSuccess(List<GatewayBean> list) { + //鍙戣捣鍒犻櫎鐢电珯鎸囦护 + deleteResidence(position, houseIdBean, list); - } + } - @Override - public void onFailure(HDLException e) { - //鍙戣捣鍒犻櫎鐢电珯鎸囦护 - deleteResidence(position, houseIdBean, null); - } - }); + @Override + public void onFailure(HDLException e) { + //鍙戣捣鍒犻櫎鐢电珯鎸囦护 + deleteResidence(position, houseIdBean, null); + } + }); + } else { + //銆愮畝鏄撴柟寮忋�戝彂璧峰垹闄ょ數绔欐寚浠� + deleteResidence(position, houseIdBean, null); + } } } }); @@ -1053,8 +1062,8 @@ public void requestPermissions(OnCallBeak onCallBeak) { - //ACCESS_FINE_LOCATION 鍏佽浣跨敤GPS瀹氫綅 - //ACCESS_COARSE_LOCATION 鍏佽浣跨敤WIFI鐑偣鎴栧熀绔欐潵鑾峰彇绮楃暐鐨勫畾浣� + //ACCESS_FINE_LOCATION 鍏佽浣跨敤GPS瀹氫綅 + //ACCESS_COARSE_LOCATION 鍏佽浣跨敤WIFI鐑偣鎴栧熀绔欐潵鑾峰彇绮楃暐鐨勫畾浣� String[] ary = PermissionUtils.checkPermission(_mActivity, new String[]{Manifest.permission.ACCESS_FINE_LOCATION, Manifest.permission.ACCESS_COARSE_LOCATION}); if (ary.length > 0) { this.requestPermissions(ary, PermissionUtils.STATUS_SUCCESS); @@ -1244,4 +1253,4 @@ } -} +} \ No newline at end of file -- Gitblit v1.8.0