mac
2024-05-17 b754ad3b6dab239842ee69cabfb5a4a738e61f5e
2024年05月17日18:02:08

备份代码
2个文件已修改
18 ■■■■ 已修改文件
app/src/main/java/com/hdl/photovoltaic/other/HdlResidenceLogic.java 7 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
app/src/main/java/com/hdl/photovoltaic/ui/powerstation/HouseAndDeviceFragment.java 11 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
app/src/main/java/com/hdl/photovoltaic/other/HdlResidenceLogic.java
@@ -78,10 +78,10 @@
    }
    public void clearHouseList() {
        if (houseInfoList == null) {
            return;
        if (mHouseIdList != null && mHouseIdList.size() > 0) {
            mHouseIdList.clear();
        }
        if (houseInfoList.size() > 0) {
        if (houseInfoList != null && houseInfoList.size() > 0) {
            houseInfoList.clear();
        }
    }
@@ -580,6 +580,7 @@
        });
    }
    /**
     * 电站状态概览(安装商)
     */
app/src/main/java/com/hdl/photovoltaic/ui/powerstation/HouseAndDeviceFragment.java
@@ -22,6 +22,7 @@
import com.hdl.photovoltaic.databinding.FragmentHouseListBinding;
import com.hdl.photovoltaic.base.CustomBaseFragment;
import com.hdl.photovoltaic.enums.HomepageTitleTabSwitch;
import com.hdl.photovoltaic.enums.PowerStationStatus;
import com.hdl.photovoltaic.enums.ShowErrorMode;
import com.hdl.photovoltaic.enums.SortType;
import com.hdl.photovoltaic.enums.SortValue;
@@ -82,7 +83,7 @@
    private String installedCapacityMinValue = "";//最小组串容量(装机容量)
    private String installedCapacityMaxValue = "";//最大组串容量(装机容量)
    private String gridTypeValue = "";//并网状态(全部 不传该过滤参数,FULL_GRID:并网,OFFLINE:离网)
    private String powerStationStatusValue = "";//电站状态(全部 不传该过滤参数,1:正常(运行),2:离线,3:待接入,4:故障)
    private String powerStationStatusValue = PowerStationStatus.All;//电站状态(全部 不传该过滤参数,1:正常(运行),2:离线,3:待接入,4:故障)
    private final long pageSize = 20;//页数
@@ -145,6 +146,7 @@
        viewBinding.powerStationAllIl.parentLl.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
                powerStationStatusValue = PowerStationStatus.All;
                selectedStationStyle(viewBinding.powerStationAllIl.parentLl, viewBinding.powerStationAllIl.stationTotalTv, viewBinding.powerStationAllIl.stationTitleTv, true);
                loadNextPageHouseList(true, key, value, installedCapacityMinValue, installedCapacityMaxValue, gridTypeValue, powerStationStatusValue, 1, true);
            }
@@ -153,6 +155,7 @@
        viewBinding.powerStationFaultsIl.parentLl.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
                powerStationStatusValue = PowerStationStatus.malfunction;
                selectedStationStyle(viewBinding.powerStationFaultsIl.parentLl, viewBinding.powerStationFaultsIl.stationTotalTv, viewBinding.powerStationFaultsIl.stationTitleTv, true);
                loadNextPageHouseList(true, key, value, installedCapacityMinValue, installedCapacityMaxValue, gridTypeValue, powerStationStatusValue, 1, true);
            }
@@ -161,6 +164,7 @@
        viewBinding.hpowerStationOfflineIl.parentLl.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
                powerStationStatusValue = PowerStationStatus.off;
                selectedStationStyle(viewBinding.hpowerStationOfflineIl.parentLl, viewBinding.hpowerStationOfflineIl.stationTotalTv, viewBinding.hpowerStationOfflineIl.stationTitleTv, true);
                loadNextPageHouseList(true, key, value, installedCapacityMinValue, installedCapacityMaxValue, gridTypeValue, powerStationStatusValue, 1, true);
            }
@@ -169,6 +173,7 @@
        viewBinding.powerStationConnectedIl.parentLl.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
                powerStationStatusValue = PowerStationStatus.connecting;
                selectedStationStyle(viewBinding.powerStationConnectedIl.parentLl, viewBinding.powerStationConnectedIl.stationTotalTv, viewBinding.powerStationConnectedIl.stationTitleTv, true);
                loadNextPageHouseList(true, key, value, installedCapacityMinValue, installedCapacityMaxValue, gridTypeValue, powerStationStatusValue, 1, true);
            }
@@ -354,6 +359,7 @@
                viewBinding.stationNameIv.setSelected(isSelected);
                key = SortType.homeNameSort;
                value = isSelected ? SortValue.ascending : SortValue.descending;
                loadNextPageHouseList(true, key, value, installedCapacityMinValue, installedCapacityMaxValue, gridTypeValue, powerStationStatusValue, 1, true);
            }
        });
        //电站发电功率筛选
@@ -365,6 +371,7 @@
                viewBinding.stationPowerIv.setSelected(isSelected);
                key = SortType.powerSort;
                value = isSelected ? SortValue.ascending : SortValue.descending;
                loadNextPageHouseList(true, key, value, installedCapacityMinValue, installedCapacityMaxValue, gridTypeValue, powerStationStatusValue, 1, true);
            }
        });
        //电站当日发电量筛选
@@ -376,6 +383,7 @@
                viewBinding.stationDayIv.setSelected(isSelected);
                key = SortType.todayElectricitySort;
                value = isSelected ? SortValue.ascending : SortValue.descending;
                loadNextPageHouseList(true, key, value, installedCapacityMinValue, installedCapacityMaxValue, gridTypeValue, powerStationStatusValue, 1, true);
            }
        });
        //电站当月发电量筛选
@@ -387,6 +395,7 @@
                viewBinding.stationMonthIv.setSelected(isSelected);
                key = SortType.monthElectricitySort;
                value = isSelected ? SortValue.ascending : SortValue.descending;
                loadNextPageHouseList(true, key, value, installedCapacityMinValue, installedCapacityMaxValue, gridTypeValue, powerStationStatusValue, 1, true);
            }
        });
        //设备点击