linhaohong 1 год назад
Родитель
Сommit
fdbf8a152e
1 измененных файлов с 1 добавлено и 1 удалено
  1. 1 1
      AdminController/CloudServiceManage/AgentDeviceController.py

+ 1 - 1
AdminController/CloudServiceManage/AgentDeviceController.py

@@ -223,7 +223,7 @@ class AgentDeviceView(View):
             metric_type = int(request_dict.get('metric_type', 0))
 
             # endTime变成每个月最后一天
-            end_datetime = datetime.utcfromtimestamp(endTime)
+            end_datetime = datetime.fromtimestamp(endTime)
             month_str = end_datetime.strftime('%Y-%m')
             year, month = int(month_str.split('-')[0]), int(month_str.split('-')[1])
             end = calendar.monthrange(year, month)[1]