This commit is contained in:
WorldTeacher
2024-09-23 15:48:02 +02:00
parent e5816b40d2
commit e7efdc8481
7 changed files with 14 additions and 14 deletions

View File

@@ -23,7 +23,7 @@ def generate_report():
report_path = os.path.join(config.report.path, f"report_{year}_{week}.tsv")
day = QDate.currentDate().addDays(-7).toString("yyyy-MM-dd")
query = f"""SELECT * FROM loans WHERE loan_date >= '{day}';"""
# print(query)
#print(query)
colnames = ["UserId", "Title", "Action", "Datum"]
table = PrettyTable(colnames)
@@ -49,7 +49,7 @@ def generate_report():
loan_action_date,
]
)
# # print(table)
# #print(table)
# # wruitng the table to a file
# with open("report.txt", "w", encoding="utf-8") as f:
# f.write(str(table))