|
@@ -141,11 +141,12 @@ class info_path(Load):
|
|
|
type_info = device_type[value['type_id']]
|
|
|
if type_info:
|
|
|
self.data['list'][key]['type'] = type_info['name']
|
|
|
- info = gateway[value['gateway_id']]
|
|
|
- if info:
|
|
|
- self.data['list'][key]['gateway'] = info['name']
|
|
|
- else:
|
|
|
- self.data['list'][key]['gateway'] = '无'
|
|
|
+ self.data['list'][key]['gateway'] = '无'
|
|
|
+ if value['gateway_id'] in gateway:
|
|
|
+ info = gateway[value['gateway_id']]
|
|
|
+ if info:
|
|
|
+ self.data['list'][key]['gateway'] = info['name']
|
|
|
+
|
|
|
if value['status']:
|
|
|
self.data['list'][key]['status'] = '已连接'
|
|
|
else:
|