diff --git a/src/pretix/control/views/vouchers.py b/src/pretix/control/views/vouchers.py index d98b137132..06e1f5c8a1 100644 --- a/src/pretix/control/views/vouchers.py +++ b/src/pretix/control/views/vouchers.py @@ -67,7 +67,8 @@ class VoucherList(PaginationMixin, EventPermissionRequiredMixin, ListView): headers = [ _('Voucher code'), _('Valid until'), _('Product'), _('Reserve quota'), _('Bypass quota'), - _('Price effect'), _('Value'), _('Tag'), _('Redeemed'), _('Maximum usages'), _('Seat') + _('Price effect'), _('Value'), _('Tag'), _('Redeemed'), _('Maximum usages'), _('Seat'), + _('Comment') ] writer.writerow(headers) @@ -92,7 +93,8 @@ class VoucherList(PaginationMixin, EventPermissionRequiredMixin, ListView): v.tag, str(v.redeemed), str(v.max_usages), - str(v.seat) if v.seat else "" + str(v.seat) if v.seat else "", + str(v.comment) if v.comment else "" ] writer.writerow(row) diff --git a/src/tests/control/test_vouchers.py b/src/tests/control/test_vouchers.py index 2e83224014..58a3346d75 100644 --- a/src/tests/control/test_vouchers.py +++ b/src/tests/control/test_vouchers.py @@ -93,9 +93,9 @@ class VoucherFormTest(SoupTestMixin, TransactionTestCase): doc = self.client.get('/control/event/%s/%s/vouchers/?download=yes' % (self.orga.slug, self.event.slug)) assert doc.content.decode().strip() == '"Voucher code","Valid until","Product","Reserve quota",' \ '"Bypass quota","Price effect","Value","Tag","Redeemed",' \ - '"Maximum usages","Seat"' \ + '"Maximum usages","Seat","Comment"' \ '\r\n"ABCDEFG","","Early-bird ticket","No","No","No effect","","","0",' \ - '"1",""' + '"1","",""' def test_filter_status_valid(self): with scopes_disabled():