Forráskód Böngészése

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

locky 1 éve
szülő
commit
8d43b5b8a1
1 módosított fájl, 1 hozzáadás és 1 törlés
  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']: