Skip to content

Commit fbfd204

Browse files
committed
Include the note itself in email sent when the RFC editor note changes after document approval. Also changed the flow to redirect back to the writeups pages after editing the RFC editor note. Fixes ietf-tools#2672. Commit ready for merge.
- Legacy-Id: 16110
1 parent 003e472 commit fbfd204

3 files changed

Lines changed: 8 additions & 3 deletions

File tree

ietf/doc/tests_ballot.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -399,7 +399,7 @@ def test_edit_ballot_rfceditornote(self):
399399
r = self.client.post(url, dict(
400400
rfc_editor_note="This is a simple test.",
401401
save_ballot_rfceditornote="1"))
402-
self.assertEqual(r.status_code, 200)
402+
self.assertEqual(r.status_code, 302)
403403
draft = Document.objects.get(name=draft.name)
404404
self.assertTrue(draft.has_rfc_editor_note())
405405
self.assertTrue("This is a simple test" in draft.latest_event(WriteupDocEvent, type="changed_rfc_editor_note_text").text)
@@ -419,7 +419,7 @@ def test_edit_ballot_rfceditornote(self):
419419
r = self.client.post(url, dict(
420420
rfc_editor_note='This is a new note.',
421421
save_ballot_rfceditornote="1"))
422-
self.assertEqual(r.status_code, 200)
422+
self.assertEqual(r.status_code, 302)
423423
self.assertEqual(len(outbox),1)
424424
self.assertIn('RFC Editor note changed',outbox[-1]['Subject'])
425425

ietf/doc/views_ballot.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -694,6 +694,7 @@ def ballot_rfceditornote(request, name):
694694
)
695695
)
696696
send_mail_preformatted(request, msg)
697+
return redirect('ietf.doc.views_doc.document_writeup', name=doc.name)
697698

698699
if request.method == 'POST' and "clear_ballot_rfceditornote" in request.POST:
699700
e = WriteupDocEvent(doc=doc, rev=doc.rev, by=login)

ietf/templates/doc/ballot/ednote_changed_late.txt

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,5 +4,9 @@ Subject: RFC Editor note changed for {{event.doc}}
44

55
The RFC Editor note for {{event.doc}} has changed after the doc was approved.
66

7-
The new note can be seen at {{settings.IDTRACKER_BASE_URL}}{% url 'ietf.doc.views_doc.document_writeup' name=event.doc.name %}
7+
The new note is below, but can also be seen at {{settings.IDTRACKER_BASE_URL}}{% url 'ietf.doc.views_doc.document_writeup' name=event.doc.name %}
8+
9+
-----
10+
{{ event.text}}
11+
812
{% endautoescape %}

0 commit comments

Comments
 (0)