From 7942a5168bee5b593f0adee3a5868db3f9749392 Mon Sep 17 00:00:00 2001 From: zty Date: Fri, 20 Jun 2025 09:44:52 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20wpm/service=20=E4=BC=98=E5=8C=96?= =?UTF-8?q?=E7=85=A4=E7=B2=89=E7=83=AD=E5=80=BC=E8=8E=B7=E5=8F=96=E6=96=B9?= =?UTF-8?q?=E5=BC=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- apps/wpm/services.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/wpm/services.py b/apps/wpm/services.py index 1dbf5e96..7c5f8d20 100644 --- a/apps/wpm/services.py +++ b/apps/wpm/services.py @@ -134,7 +134,7 @@ def get_pcoal_heat(year_s: int, month_s: int, day_s: int): mgroup__name='回转窑', shift__name__in=['白班', '早班']) # hardcode if qs.pcoal_heat is None or qs.pcoal_heat <=0: s = SfLog.objects.filter(pcoal_heat__isnull=False).order_by('-start_time').first() - if s: + if s and s.pcoal_heat: qs.pcoal_heat = s.pcoal_heat else: qs.pcoal_heat = 25000