I have been researching on how to render a single template using two class based views and I have not found any material addressing the same. For instance the home.html template with a functionality of creating a new post and at the same time listing all the posts in the database. How do I implement such functionality.
class BlogCreateView(CreateView):
model = Post
template_name = 'home.html'
fields = ['title', 'body']
class BlogListView(ListView):
model = Post
template_name = 'home.html'