Show only camp bar products.

This commit is contained in:
Víðir Valberg Guðmundsson 2018-08-16 18:27:59 +02:00
parent ff6912fed8
commit 932d6aaa90
1 changed files with 5 additions and 1 deletions

View File

@ -1,8 +1,12 @@
from camps.mixins import CampViewMixin
from .models import ProductCategory
from django.views.generic import ListView
class MenuView(ListView):
class MenuView(CampViewMixin, ListView):
model = ProductCategory
template_name = "bar_menu.html"
context_object_name = "categories"
def get_queryset(self):
return super().get_queryset().filter(camp=self.camp)