Skip to content

Commit fa53de0

Browse files
committed
Guide the workflow back to normal nominations after nominating a new person.
- Legacy-Id: 10619
1 parent 85c13d6 commit fa53de0

2 files changed

Lines changed: 3 additions & 4 deletions

File tree

ietf/nomcom/tests.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -675,7 +675,8 @@ def nominate_newperson_view(self, *args, **kwargs):
675675
if not public:
676676
test_data['nominator_email'] = nominator_email
677677

678-
response = self.client.post(nominate_url, test_data)
678+
response = self.client.post(nominate_url, test_data,follow=True)
679+
self.assertTrue(response.redirect_chain)
679680
self.assertEqual(response.status_code, 200)
680681
q = PyQuery(response.content)
681682
self.assertContains(response, "alert-success")

ietf/nomcom/views.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -357,9 +357,7 @@ def nominate(request, year, public, newperson):
357357
form.save()
358358
messages.success(request, 'Your nomination has been registered. Thank you for the nomination.')
359359
if newperson:
360-
## This needs to redirect to the normal nominate URL instead.
361-
## Need to weed out the custom message stuff.
362-
form = NominateNewPersonForm(nomcom=nomcom, user=request.user, public=public)
360+
return redirect('nomcom_%s_nominate' % ('public' if public else 'private'), year=year)
363361
else:
364362
form = NominateForm(nomcom=nomcom, user=request.user, public=public)
365363
else:

0 commit comments

Comments
 (0)