From b60f875da2a6bba9ed2880bf0149715742776242 Mon Sep 17 00:00:00 2001 From: Ole Laursen Date: Wed, 4 Apr 2012 18:46:41 +0000 Subject: [PATCH] Remove too-simple guard on automatic ballot creation - Legacy-Id: 4258 --- ietf/wgcharter/views.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ietf/wgcharter/views.py b/ietf/wgcharter/views.py index 23a925a92..d3fdb11b3 100644 --- a/ietf/wgcharter/views.py +++ b/ietf/wgcharter/views.py @@ -106,12 +106,12 @@ def change_state(request, name, option=None): if message: email_secretariat(request, wg, "state-%s" % charter_state.slug, message) - if charter_state.slug == "intrev" and not charter.latest_event(BallotDocEvent, type="created_ballot", ballot_type__slug="r-extrev"): + if charter_state.slug == "intrev": e = BallotDocEvent(type="created_ballot", by=login, doc=charter) e.ballot_type = BallotType.objects.get(doc_type=charter.type, slug="r-extrev") e.desc = u"Created ballot for approving charter for external review" e.save() - elif charter_state.slug == "iesgrev" and not charter.latest_event(BallotDocEvent, type="created_ballot", ballot_type__slug="approve"): + elif charter_state.slug == "iesgrev": e = BallotDocEvent(type="created_ballot", by=login, doc=charter) e.ballot_type = BallotType.objects.get(doc_type=charter.type, slug="approve") e.desc = u"Created ballot for approving charter" @@ -490,7 +490,7 @@ def ballot_writeupnotes(request, name): e.save() if "issue_ballot" in request.POST and approval: - if has_role(request.user, "Area Director") and not charter.latest_event(GroupBallotPositionDocEvent, ad=login, time__gte=started_process.time): + if has_role(request.user, "Area Director") and not charter.latest_event(BallotPositionDocEvent, ad=login, time__gte=started_process.time): # sending the ballot counts as a yes pos = GroupBallotPositionDocEvent(doc=charter, by=login) pos.type = "changed_ballot_position"