Browse Source

更新 'front/api/main.py'

rabin 6 years ago
parent
commit
3f23de6e78
1 changed files with 5 additions and 5 deletions
  1. 5 5
      front/api/main.py

+ 5 - 5
front/api/main.py

@@ -44,10 +44,10 @@ class index_path(Load):
 			self.data['msg'] = str(99) + '+'
             
         self.data['pic'] = []
-			pic = self.service('common').list('device_info', state=True, search={'hardware_type':6, 'farm_id':self.data['info']['farm_id']})
-			if pic:
-				for key, value in enumerate(pic):
-					pic[key]['cdates'] = Demeter.date(value['cdate'])
-				self.data['pic'] = pic
+        pic = self.service('common').list('device_info', state=True, search={'hardware_type':6, 'farm_id':self.data['info']['farm_id']})
+        if pic:
+          for key, value in enumerate(pic):
+            pic[key]['cdates'] = Demeter.date(value['cdate'])
+            self.data['pic'] = pic
 
 		self.out('yes', self.data)