From 22408b16c780cc5e6eeef439235ebf86de927b06 Mon Sep 17 00:00:00 2001 From: Yohann D'ANELLO Date: Mon, 26 Oct 2020 14:38:03 +0100 Subject: [PATCH] Capitalize title --- media/management/commands/export_markdown_site.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/media/management/commands/export_markdown_site.py b/media/management/commands/export_markdown_site.py index d7d13d2..615b3fc 100644 --- a/media/management/commands/export_markdown_site.py +++ b/media/management/commands/export_markdown_site.py @@ -17,9 +17,9 @@ class Command(BaseCommand): directory = options["directory"] for model_class, file_name in [(BD, "bd.md"), (Manga, "mangas.md"), (Roman, "romans.md"), - (CD, "cd.md"), (Vinyle, "vinyle.md")]: + (CD, "cd.md"), (Vinyle, "vinyles.md")]: with open(directory + "/docs/" + file_name, "w") as f: - f.write("# " + str(model_class._meta.verbose_name) + "\n\n\n") + f.write("# " + str(model_class._meta.verbose_name_plural).capitalize() + "\n\n\n") titles = list(set(obj["title"] for obj in model_class.objects.values("title").distinct().all())) titles.sort()