Explorar el Código

修改保存的场景数据条件的event_type为整型

locky hace 1 año
padre
commit
8d43b5b8a1
Se han modificado 1 ficheros con 1 adiciones y 1 borrados
  1. 1 1
      Controller/SensorGateway/SmartSceneController.py

+ 1 - 1
Controller/SensorGateway/SmartSceneController.py

@@ -1228,7 +1228,7 @@ class SmartSceneView(View):
                 condition['time_dict'] = time_dict
         else:
             device_type = int(conditions_dict['sensor']['device_type'])
-            event_type = conditions_dict['sensor']['eventValues'][0]['event_type']
+            event_type = int(conditions_dict['sensor']['eventValues'][0]['event_type'])
             condition['event_type'] = event_type
             # 温湿度传感器,取值
             if device_type == SENSOR_TYPE['tem_hum_sensor']: