From 00a432ed481be1f2816499048336f0f055d7786f Mon Sep 17 00:00:00 2001 From: luxagraf Date: Sat, 15 Aug 2020 14:09:09 -0400 Subject: moved fieldnotes into posts, finished builder for those --- app/builder/base.py | 4 ++-- app/builder/views.py | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) (limited to 'app/builder') diff --git a/app/builder/base.py b/app/builder/base.py index b41bbba..fabea6e 100644 --- a/app/builder/base.py +++ b/app/builder/base.py @@ -74,7 +74,7 @@ class BuildNew(): self.write_file(path, response.content) def build_year_view(self, url, paginate_by=99999): - years = self.model.objects.dates('pub_date', 'year') + years = self.get_model_queryset().dates('pub_date', 'year') for year in years: year = year.strftime('%Y') qs = self.model.objects.filter( @@ -88,7 +88,7 @@ class BuildNew(): ) def build_month_view(self, url, paginate_by=99999): - months = self.model.objects.dates('pub_date', 'month') + months = self.get_model_queryset().dates('pub_date', 'month') for m in months: year = m.strftime('%Y') month = m.strftime('%m') diff --git a/app/builder/views.py b/app/builder/views.py index d70eb4b..cbb33fb 100644 --- a/app/builder/views.py +++ b/app/builder/views.py @@ -8,9 +8,9 @@ from sightings.build import builder as sightings_builder from photos.build import builder as photo_builder #from notes.build import builder as notes_builder from pages.build import builder as page_builder -from fieldnotes.build import builder as fieldnotes_builder +#from fieldnotes.build import builder as fieldnotes_builder from photos.build import dailybuilder -from posts.build import src_builder, guide_builder +from posts.build import src_builder, guide_builder, fieldnotes_builder options = { 'writing': BuildWriting, -- cgit v1.2.3-70-g09d2