Selaa lähdekoodia

修改查询首页设备返回空房间数据

peng 3 vuotta sitten
vanhempi
commit
1ddf9d8a88
1 muutettua tiedostoa jossa 1 lisäystä ja 1 poistoa
  1. 1 1
      Controller/SensorGateway/EquipmentFamilyController.py

+ 1 - 1
Controller/SensorGateway/EquipmentFamilyController.py

@@ -1017,7 +1017,7 @@ class EquipmentFamilyView(View):
             if room_id:
                 family_room = FamilyRoom.objects.filter(id=room_id)
                 if not family_room.exists():
-                    return response.json(173)
+                    return response.json(0, device_dict)
                 family_room_device_qs = family_room_device_qs.filter(room_id=room_id)
             # 处理网关摄像头
             gateways_or_cameras_qs = family_room_device_qs.filter(sub_device=0)[(page - 1) * line:page * line]