Add basic tracking of when an event authorisation request was sent.

Designed and requested by Ross because he can't remember if he's push a button...
This commit is contained in:
Tom Price
2017-04-19 18:14:36 +01:00
parent d9076a4f5f
commit 331dab20f7
6 changed files with 99 additions and 24 deletions

View File

@@ -1086,3 +1086,9 @@ class TECEventAuthorisationTest(TestCase):
email = mail.outbox[0]
self.assertIn('client@functional.test', email.to)
self.assertIn('/event/%d/' % (self.event.pk), email.body)
# Check sent by details are populated
self.event.refresh_from_db()
self.assertEqual(self.event.auth_request_by, self.profile)
self.assertEqual(self.event.auth_request_to, 'client@functional.test')
self.assertIsNotNone(self.event.auth_request_at)