From c1168b02a8e8690d52f727823c295f6ef8d6560b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=8E=8B=E6=96=87=E8=89=B3?= Date: Wed, 20 Aug 2025 14:10:55 +0800 Subject: [PATCH] fix bug --- dags/office/sell/base_price.py | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/dags/office/sell/base_price.py b/dags/office/sell/base_price.py index 4dbccec..f565c2a 100644 --- a/dags/office/sell/base_price.py +++ b/dags/office/sell/base_price.py @@ -34,8 +34,13 @@ def calc(**kwargs): year_month = conf.get('year_month', '') district = conf.get('district', '') office_name = conf.get('name', '') - - if pd.isna(office_name) or office_name == "": + if city == "": + city = None + if district == "": + district = None + if office_name == "": + office_name = None + if pd.isna(office_name): calcByCity(city, year_month) else: # 直接重算出最近一年的数据,保证一年有数据