Skip to content

Commit

Permalink
Worked out the build
Browse files Browse the repository at this point in the history
  • Loading branch information
palewire committed Aug 28, 2017
1 parent dfc1c11 commit 46fe503
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
6 changes: 6 additions & 0 deletions example/date_views/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,12 @@ class MyDayArchiveView(BuildableDayArchiveView):
class MyDetailView(BuildableDetailView):
queryset = Dateline.objects.all()

def set_kwargs(self, obj):
self.kwargs = {
'state_slug': obj.state_slug,
'city_slug': obj.city_slug,
}

def get_object(self, queryset=None):
return self.queryset.get(
state_slug=self.kwargs['state_slug'],
Expand Down
1 change: 1 addition & 0 deletions example/project/settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -128,6 +128,7 @@
'date_views.views.MyYearArchiveView',
'date_views.views.MyMonthArchiveView',
'date_views.views.MyDayArchiveView',
'date_views.views.MyDetailView',
)
BUILD_DIR = os.path.join(BASE_DIR, '.build/')
STATIC_ROOT = os.path.join(BASE_DIR, '.static/')
Expand Down

0 comments on commit 46fe503

Please sign in to comment.