From c5a587a3bae342cef19996388091597ed6bc4a7b Mon Sep 17 00:00:00 2001
From: Todd Dembrey <todd.dembrey@torchbox.com>
Date: Mon, 3 Sep 2018 12:00:34 +0100
Subject: [PATCH] Perform specific on the QS not the object

---
 opentech/apply/home/models.py                                 | 4 ++--
 opentech/apply/home/templates/apply_home/apply_home_page.html | 4 ++--
 2 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/opentech/apply/home/models.py b/opentech/apply/home/models.py
index 3d135ce17..6b1489d1d 100644
--- a/opentech/apply/home/models.py
+++ b/opentech/apply/home/models.py
@@ -24,6 +24,6 @@ class ApplyHomePage(Page):
 
     def get_context(self, *args, **kwargs):
         context = super().get_context(*args, **kwargs)
-        context['open_funds'] = ApplicationBase.objects.order_by_end_date()
-        context['open_labs'] = LabBase.objects.public().live()
+        context['open_funds'] = ApplicationBase.objects.order_by_end_date().specific()
+        context['open_labs'] = LabBase.objects.public().live().specific()
         return context
diff --git a/opentech/apply/home/templates/apply_home/apply_home_page.html b/opentech/apply/home/templates/apply_home/apply_home_page.html
index 041adf22b..ac43d0e34 100644
--- a/opentech/apply/home/templates/apply_home/apply_home_page.html
+++ b/opentech/apply/home/templates/apply_home/apply_home_page.html
@@ -17,10 +17,10 @@
 
     <div class="wrapper wrapper--listings">
     {% for fund in open_funds %}
-        {% include "apply_home/includes/apply_listing.html" with page=fund.specific %}
+        {% include "apply_home/includes/apply_listing.html" with page=fund %}
     {% endfor %}
     {% for lab in open_labs %}
-        {% include "apply_home/includes/apply_listing.html" with page=lab.specific %}
+        {% include "apply_home/includes/apply_listing.html" with page=lab %}
     {% endfor %}
     </div>
 
-- 
GitLab