diff --git a/project/views.py b/project/views.py index 58524407..2a4e9fea 100644 --- a/project/views.py +++ b/project/views.py @@ -115,12 +115,12 @@ class IndexView(TemplateView): 'online_coming_soon': online_coming_soon, 'school_schedule': school_schedule, 'course_items': Course.shuffle(Course.objects.filter(status=Course.PUBLISHED)[:3]), - 'is_purchased': camp_payment_exists, # school_payment_exists, + 'is_purchased': camp_payment_exists, 'camp_price': DrawingCampPayment.MONTH_PRICE, 'min_school_price': SchoolSchedule.objects.aggregate(Min('month_price'))['month_price__min'], 'school_schedules': SchoolSchedule.objects.filter(weekday__in=DrawingCampPayment.WEEKDAYS, is_camp=True), 'school_schedules_purchased': DrawingCampPayment.WEEKDAYS if camp_payment_exists else [], - 'teachers': teachers, + 'teachers': sorted(list(teachers), key=lambda t: 1 if t.email == 'sasha@lil.city' else 0, reverse=True), 'works_count': Payment.objects.filter(status__in=Payment.PW_PAID_STATUSES).count() * 7, 'subscription_ends': camp_payment.latest('date_end').date_end if camp_payment_exists else None, 'subscription_ends_humanize': camp_payment.latest('date_end').date_end_humanize if camp_payment_exists else None,