wjc
2025-04-15 cdf49871675e42a5576f725a93eec7ca15294c6f
app/src/main/java/com/hdl/photovoltaic/ui/CPowerStationActivity.java
@@ -72,6 +72,7 @@
    @Override
    public void onBindView(Bundle savedInstanceState) {
        setStatusBarTranslucent();
        getWindow().setNavigationBarColor(getColor(R.color.text_FF000000));
        //C端启动App自动打开小程序电站详情界面
        startAppAutomaticallyOpenUni();
        //注册监听
@@ -230,10 +231,12 @@
//        }
        if (TextUtils.isEmpty(HDLLinkPMUser.getInstance().getAccessToken())) {
            //其实刷新token失败已通知退出登录,数据已经清空,因为等2s uni加载慢导致请求链接的时候出现token为空
            HdlLogLogic.print("返回去");
            return;
        }
        UserConfigManage.getInstance().setUniBottomSafeDistanceBackgroundColor(0);
        List<HouseIdBean> HouseIdList = HdlResidenceLogic.getInstance().getHouseIdList();
        if (HouseIdList.size() == 0) {
        if (HouseIdList.isEmpty()) {
            if (TextUtils.isEmpty(UserConfigManage.getInstance().getHomeId())) {
                String path = HDLUniMP.UNI_EVENT_OPEN_HOME_Null_C;
                HdlUniLogic.getInstance().openUniMP(path, null);
@@ -449,7 +452,18 @@
                        }
                    } else if (linkResponse.getTopic().endsWith("/app/thing/property/send")) {
                        //设备状态变更topic:/user/${homeId}/app/thing/property/send
                        if (linkResponse.getData() == null) {
                            HdlLogLogic.print("设备状态变更--->数据为空", false);
                            return;
                        }
                        HDLUniMP.UniCallBackBaseBean uniCallBackBaseBean = new HDLUniMP.UniCallBackBaseBean();
                        uniCallBackBaseBean.setType(linkResponse.getTopic());
                        uniCallBackBaseBean.setData(linkResponse.getData());
                        HdlUniLogic.getInstance().sendUni(HDLUniMP.UNI_EVENT_NOTIFICATION_DEVICE_MODEL, uniCallBackBaseBean);
                    }
                }
            }
        };