feature: load edition metadata from directus

This commit is contained in:
Prof. Dr. Matthias Jung DL9MJ
2025-06-24 22:04:12 +02:00
committed by Tim Grelka
parent d3a554ea1d
commit e1d7113a96
3 changed files with 25 additions and 30 deletions
+8 -1
View File
@@ -52,8 +52,15 @@ class Download:
}
)
out_edition = {
"title": in_edition["title"],
"abstract": in_edition["abstract"],
"chapters": out_chapters,
"edition": edition,
}
with open("data/book_" + edition + ".json", "w", encoding="utf-8") as file:
json.dump(out_chapters, file, ensure_ascii=False, indent=4)
json.dump(out_edition, file, ensure_ascii=False, indent=4)
def download_question_metadata(self):
questions = self.api.get(