from django.urls import reverse from django.apps import apps from builder.base import BuildNew from itertools import chain from django.conf import settings class BuildPosts(BuildNew): def build(self): self.build_list_view( base_path=reverse("essay-list:list"), paginate_by=50 ) self.build_list_view( base_path=reverse("guide-list:list"), paginate_by=50 ) self.build_detail_view() def posts_builder(): j = BuildPosts("posts", "post") j.build()