From 7f1f3df956d8d601c9e6faab6ac8ae6e4be3853e Mon Sep 17 00:00:00 2001 From: caoqianming Date: Mon, 9 Oct 2023 16:52:16 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E7=85=A4=E7=B2=89=E7=83=AD=E5=80=BC?= =?UTF-8?q?=E7=B3=BB=E6=95=B0=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- apps/enm/tasks.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/apps/enm/tasks.py b/apps/enm/tasks.py index 1435c95d..2d18ef5e 100644 --- a/apps/enm/tasks.py +++ b/apps/enm/tasks.py @@ -471,7 +471,7 @@ def cal_enstat(type, sflogId, mgroupId, year, month, day, hour, year_s, month_s, if type in ['hour_s', 'sflog', 'day_s']: enstat.pcoal_heat = get_pcoal_heat( enstat.year_s, enstat.month_s, enstat.day_s) - enstat.pcoal_coal_consume = enstat.pcoal_consume * enstat.pcoal_heat/7000 + enstat.pcoal_coal_consume = enstat.pcoal_consume * enstat.pcoal_heat/29307 elif type == 'month_st': enstat.pcoal_coal_consume = EnStat.objects.filter( type='sflog', mgroup=enstat.mgroup, year_s=year_s, month_s=month_s, sflog__team=enstat.team).aggregate(sum=Sum('pcoal_coal_consume'))['sum'] @@ -664,7 +664,7 @@ def cal_enstat_pcoal_change(enstat, new_pcoal_heat): type = enstat.type if type in ['hour_s', 'sflog', 'day_s']: enstat.pcoal_heat = new_pcoal_heat - enstat.pcoal_coal_consume = enstat.pcoal_consume * enstat.pcoal_heat/7000 + enstat.pcoal_coal_consume = enstat.pcoal_consume * enstat.pcoal_heat/29307 elif type == 'month_st': enstat.pcoal_coal_consume = EnStat.objects.filter(type='sflog', mgroup=enstat.mgroup, year_s=enstat.year_s, month_s=enstat.month_s, sflog__team=enstat.team).aggregate(sum=Sum('pcoal_coal_consume'))['sum']