I have the following listview and detailview structure. I would like to pass in a form to be shown with each object that is listed in the listview (and also with the one object when there is detailview). How can I get this to show up with each object?
class ObjectListView(LoginRequiredMixin, ListView):
model = Object
...
date = (datetime.now() - timedelta(hours = 7)).date()
queryset = Object.objects.filter(date=date)
def get(self, request, *args, **kwargs):
...
return super().get(request, *args, **kwargs)
class ObjectDetailView(LoginRequiredMixin, DetailView):
model = Object
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…