Skip to content

Commit

Permalink
reverify event/views.py
Browse files Browse the repository at this point in the history
  • Loading branch information
carmen-chau committed Jun 29, 2024
1 parent 2d1f8f4 commit eb969d1
Showing 1 changed file with 0 additions and 23 deletions.
23 changes: 0 additions & 23 deletions hackathon_site/event/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -117,19 +117,6 @@ def get_context_data(self, **kwargs):
review = self.request.user.application.review

context["review"] = review
if settings.RSVP:
context[
"rsvp_passed"
] = _now().date() > review.decision_sent_date + timedelta(
days=settings.RSVP_DAYS
)
rsvp_deadline = datetime.combine(
review.decision_sent_date + timedelta(days=settings.RSVP_DAYS),
datetime.max.time(), # 11:59PM
)
context["rsvp_deadline"] = settings.TZ_INFO.localize(
rsvp_deadline
).strftime("%B %-d, %Y, %-I:%M %p %Z")
else:
context["review"] = None

Expand All @@ -147,12 +134,6 @@ def get_context_data(self, **kwargs):
and self.request.user.application.review.decision_sent_date is None
):
context["status"] = "Application Complete"
elif (
hasattr(self.request.user.application, "review")
and self.request.user.application.review.status == "Accepted"
and self.request.user.application.rsvp is None
):
context["status"] = "Accepted, awaiting RSVP"
elif (
hasattr(self.request.user.application, "review")
and self.request.user.application.review.status == "Waitlisted"
Expand All @@ -163,10 +144,6 @@ def get_context_data(self, **kwargs):
and self.request.user.application.review.status == "Rejected"
):
context["status"] = "Rejected"
elif self.request.user.application.rsvp:
context["status"] = "Will Attend (Accepted)"
elif not self.request.user.application.rsvp:
context["status"] = "Cannot Attend (Declined)"
else:
context["status"] = "Unknown"

Expand Down

0 comments on commit eb969d1

Please sign in to comment.