From 30dd2bff4bcb91be35c058bcd84a3049b7ee35ff Mon Sep 17 00:00:00 2001 From: mac <user@users-MacBook-Pro.local> Date: 星期五, 06 九月 2024 17:46:01 +0800 Subject: [PATCH] 2024年09月06日17:45:55 --- app/src/main/java/com/hdl/photovoltaic/ui/powerstation/HouseAndDeviceFragment.java | 48 ++++++++++++++++++++++++------------------------ 1 files changed, 24 insertions(+), 24 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 c1c7ad4..e1ab804 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 @@ -18,7 +18,6 @@ import com.hdl.photovoltaic.R; import com.hdl.photovoltaic.bean.PageNumberObject; import com.hdl.photovoltaic.config.ConstantManage; -import com.hdl.photovoltaic.config.UserConfigManage; import com.hdl.photovoltaic.databinding.FragmentHouseListBinding; import com.hdl.photovoltaic.base.CustomBaseFragment; import com.hdl.photovoltaic.enums.HomepageTitleTabSwitch; @@ -94,7 +93,7 @@ /** * 杩樺師鏉′欢鐨勫垵濮嬪寲鐘舵�� */ - private void InitializationState() { + private void initializationState() { key = SortValue.all; value = SortValue.all; installedCapacityMinValue = ""; @@ -130,7 +129,7 @@ } isClickPowerStationLabel = true; selectedTitleLabelStyle(); - InitializationState(); + initializationState(); getStatusOverview(); loadNextPageHouseList(true, key, value, installedCapacityMinValue, installedCapacityMaxValue, gridTypeValue, powerStationStatusValue, 1, true); @@ -676,10 +675,10 @@ } else if (eventBus.getTopic().equals(ConstantManage.homepage_title_tab_switch)) { + // 鍙栨秷绮樻�т簨浠� + EventBus.getDefault().removeStickyEvent(eventBus); //鎺ユ敹澶栭儴鐐瑰嚮浜嬩欢 if (eventBus.getType().equals(HomepageTitleTabSwitch.powerstation.toString())) { - // 鍙栨秷绮樻�т簨浠� - EventBus.getDefault().removeStickyEvent(eventBus); HdlLogLogic.print("姝e湪鐐瑰嚮銆愮數绔欍��"); // if (!isReadData) { // //1锛屼粠棣栭〉-鏁呴殰-杩涙潵-鐢电珯锛堜笉璇诲彇锛� @@ -690,27 +689,28 @@ //2024骞�06鏈�24鏃�14:34:01 浜у搧缁忕悊瑕佹眰杩涘幓鐢电珯鍒楄〃閮借璇诲彇 涓旈粯璁よ繘鍘婚兘鏄粯璁ょ數绔欐爣绛� isClickPowerStationLabel = true; selectedTitleLabelStyle(); - InitializationState(); + initializationState(); getStatusOverview(); loadNextPageHouseList(true, key, value, installedCapacityMinValue, installedCapacityMaxValue, gridTypeValue, powerStationStatusValue, 1, true); - - - } else if (eventBus.getType().equals(PowerStationStatus.All)) { - isClickPowerStationLabel = true; - selectedTitleLabelStyle(); - viewBinding.powerStationAllIl.parentLl.performClick(); - } else if (eventBus.getType().equals(PowerStationStatus.malfunction)) { - isClickPowerStationLabel = true; - selectedTitleLabelStyle(); - viewBinding.powerStationFaultsIl.parentLl.performClick(); - } else if (eventBus.getType().equals(PowerStationStatus.off)) { - isClickPowerStationLabel = true; - selectedTitleLabelStyle(); - viewBinding.powerStationOfflineIl.parentLl.performClick(); - } else if (eventBus.getType().equals(PowerStationStatus.connecting)) { - isClickPowerStationLabel = true; - selectedTitleLabelStyle(); - viewBinding.powerStationConnectedIl.parentLl.performClick(); + } else if (eventBus.getType().equals(ConstantManage.station_page)) { + //閫氳繃棣栭〉鐢电珯杩涙潵鐨� + if (eventBus.getData().equals(PowerStationStatus.All)) { + isClickPowerStationLabel = true; + selectedTitleLabelStyle(); + viewBinding.powerStationAllIl.parentLl.performClick(); + } else if (eventBus.getData().equals(PowerStationStatus.malfunction)) { + isClickPowerStationLabel = true; + selectedTitleLabelStyle(); + viewBinding.powerStationFaultsIl.parentLl.performClick(); + } else if (eventBus.getData().equals(PowerStationStatus.off)) { + isClickPowerStationLabel = true; + selectedTitleLabelStyle(); + viewBinding.powerStationOfflineIl.parentLl.performClick(); + } else if (eventBus.getData().equals(PowerStationStatus.connecting)) { + isClickPowerStationLabel = true; + selectedTitleLabelStyle(); + viewBinding.powerStationConnectedIl.parentLl.performClick(); + } } else if (eventBus.getType().equals(ConstantManage.station_edit)) { //缂栬緫鍚庢洿鏂颁竴涓嬩綇瀹呭垪琛� //loadNextPageHouseList(false, key, value, installedCapacityMinValue, installedCapacityMaxValue, gridTypeValue, powerStationStatusValue, 1, true); -- Gitblit v1.8.0