From f35f4792117586476b92ba4c2403c8fd8c05c025 Mon Sep 17 00:00:00 2001 From: EightyDollars Date: Fri, 17 Nov 2023 09:34:57 +0800 Subject: [PATCH] =?UTF-8?q?fix:=E6=8A=A5=E8=A1=A8=E6=97=A5=E6=9C=9F?= =?UTF-8?q?=E6=8F=90=E5=89=8D=E4=B8=80=E5=A4=A9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- server.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/server.py b/server.py index 559064e05..4da85f84b 100755 --- a/server.py +++ b/server.py @@ -338,7 +338,7 @@ def get_report_data(): for item in data: format_data.append({ - "日期": item['Unnamed: 0'], + "日期": date2str(str2date(item['Unnamed: 0']) - datetime.timedelta(days=1)), '作战录像': item['作战录像'], '赤金': item['赤金'], '龙门币订单': item['龙门币订单'], @@ -349,7 +349,7 @@ def get_report_data(): if len(format_data) < 15: for i in range(1, 16 - len(format_data)): format_data.insert(0, { - "日期": date2str(earliest_date - datetime.timedelta(days=i)), + "日期": date2str(earliest_date - datetime.timedelta(days=i+1)), '作战录像': '-', '赤金': '-', '龙门币订单': '-', @@ -394,7 +394,7 @@ def get_half_month_data(): for item in data: total_orundum = total_orundum + item['合成玉'] format_data.append({ - "日期": item['Unnamed: 0'], + "日期": date2str(str2date(item['Unnamed: 0']) - datetime.timedelta(days=1)), '合成玉': item['合成玉'], '合成玉订单数量': item['合成玉订单数量'], '抽数': round((item['合成玉'] / 600), 1), @@ -405,7 +405,7 @@ def get_half_month_data(): earliest_date = str2date(data[0]['Unnamed: 0']) for i in range(1, 16 - len(format_data)): format_data.insert(0, { - "日期": date2str(earliest_date - datetime.timedelta(days=i)), + "日期": date2str(earliest_date - datetime.timedelta(days=i+1)), '合成玉': '-', '合成玉订单数量': '-', '抽数': '-',