mac
2024-05-16 7fdae87bc3de46b5b012f8987c6902cd8b054323
app/src/main/java/com/hdl/photovoltaic/ui/powerstation/HouseListFragment.java
@@ -88,6 +88,9 @@
    @Override
    public void onBindView(Bundle savedInstanceState) {
        //放在这里也对,这里只是被创建一次
//        loadNextPageHouseList(true, key, value, installedCapacityMinValue, installedCapacityMaxValue, gridTypeValue, powerStationStatusValue, 1, true);
//        getStatusOverview();
        initData();
        //初始化
        initView();
@@ -494,8 +497,13 @@
            //接收外部点击事件
            if (eventBus.getType().equals(HomepageTitleTabSwitch.powerstation.toString())) {
                HdlLogLogic.print("正在点击【电站】");
//                HdlThreadLogic.runSubThread(new Runnable() {
//                    @Override
//                    public void run() {
                loadNextPageHouseList(true, key, value, installedCapacityMinValue, installedCapacityMaxValue, gridTypeValue, powerStationStatusValue, 1, true);
                getStatusOverview();
//                    }
//                });
            }
        }
@@ -541,15 +549,7 @@
     * @param pageNo               页码
     * @param isClear              是否清除数据
     */
    private void loadNextPageHouseList(boolean isRefreshing,
                                       String key,
                                       String keyValue,
                                       String installedCapacityMin,
                                       String installedCapacityMax,
                                       String gridType,
                                       String powerStationStatus,
                                       long pageNo,
                                       boolean isClear) {
    private void loadNextPageHouseList(boolean isRefreshing, String key, String keyValue, String installedCapacityMin, String installedCapacityMax, String gridType, String powerStationStatus, long pageNo, boolean isClear) {
        if (isClear) {
            clearData();
        }
@@ -565,14 +565,7 @@
        }
        //获取住宅(电站)ID列表
        HdlResidenceLogic.getInstance().getResidenceIdList(
                key,
                keyValue,
                installedCapacityMin,
                installedCapacityMax,
                gridType,
                powerStationStatus,
                pageNo, pageSize, new CloudCallBeak<HdlResidenceLogic.HouseBeanClass>() {
        HdlResidenceLogic.getInstance().getResidenceIdList(key, keyValue, installedCapacityMin, installedCapacityMax, gridType, powerStationStatus, pageNo, pageSize, new CloudCallBeak<HdlResidenceLogic.HouseBeanClass>() {
                    @Override
                    public void onSuccess(HdlResidenceLogic.HouseBeanClass houseBeanClass) {
                        HdlThreadLogic.runMainThread(new Runnable() {