invoicing: accounting code in csv export (#89025)
gitea/lingo/pipeline/head This commit looks good
Details
gitea/lingo/pipeline/head This commit looks good
Details
This commit is contained in:
parent
ce3a2e28f4
commit
7213bb59a1
|
@ -440,6 +440,7 @@ class RegieInvoiceListView(ListView):
|
|||
if self.full:
|
||||
headers += [
|
||||
_('Description'),
|
||||
_('Accounting code'),
|
||||
_('Unit amount'),
|
||||
_('Quantity'),
|
||||
]
|
||||
|
@ -501,6 +502,7 @@ class RegieInvoiceListView(ListView):
|
|||
yesno(invoice.payer_demat),
|
||||
yesno(invoice.payer_direct_debit),
|
||||
line.label,
|
||||
line.accounting_code,
|
||||
line.unit_amount,
|
||||
line.quantity,
|
||||
line.total_amount,
|
||||
|
|
|
@ -600,12 +600,12 @@ def test_regie_invoices(app, admin_user, orphan):
|
|||
assert len([a for a in resp.text.split('\r\n') if a]) == 1 + 5
|
||||
assert resp.text == (
|
||||
'Number,Payer ID,Payer first name,Payer last name,Publication date,Payment deadline,Due date,Demat,Direct debit,'
|
||||
'Description,Unit amount,Quantity,Total due,Payment type,Paid amount,Status\r\n'
|
||||
'F%02d-%s-0000003,payer:3,First3,Name3,2022-10-01,2022-10-31,2022-10-31,no,yes,Event A,1.00,1.00,1.00,,0.00,Not paid\r\n'
|
||||
'F%02d-%s-0000002,payer:2,First2,Name2,2022-10-01,2022-10-31,2022-10-31,no,yes,Event AA,1.00,1.00,1.00,"CESU, Cash",1.00,Paid\r\n'
|
||||
'F%02d-%s-0000001,payer:1,First1,Name1,2022-10-01,2022-10-31,2022-10-31,yes,no,Event A,1.00,1.20,1.20,Cash,1.00,Partially paid\r\n'
|
||||
'F%02d-%s-0000001,payer:1,First1,Name1,2022-10-01,2022-10-31,2022-10-31,yes,no,Event B,2.00,1.00,2.00,,0.00,Not paid\r\n'
|
||||
'F%02d-%s-0000001,payer:1,First1,Name1,2022-10-01,2022-10-31,2022-10-31,yes,no,Event A,3.00,1.00,3.00,,0.00,Not paid\r\n'
|
||||
'Description,Accounting code,Unit amount,Quantity,Total due,Payment type,Paid amount,Status\r\n'
|
||||
'F%02d-%s-0000003,payer:3,First3,Name3,2022-10-01,2022-10-31,2022-10-31,no,yes,Event A,,1.00,1.00,1.00,,0.00,Not paid\r\n'
|
||||
'F%02d-%s-0000002,payer:2,First2,Name2,2022-10-01,2022-10-31,2022-10-31,no,yes,Event AA,424242,1.00,1.00,1.00,"CESU, Cash",1.00,Paid\r\n'
|
||||
'F%02d-%s-0000001,payer:1,First1,Name1,2022-10-01,2022-10-31,2022-10-31,yes,no,Event A,424242,1.00,1.20,1.20,Cash,1.00,Partially paid\r\n'
|
||||
'F%02d-%s-0000001,payer:1,First1,Name1,2022-10-01,2022-10-31,2022-10-31,yes,no,Event B,424243,2.00,1.00,2.00,,0.00,Not paid\r\n'
|
||||
'F%02d-%s-0000001,payer:1,First1,Name1,2022-10-01,2022-10-31,2022-10-31,yes,no,Event A,424242,3.00,1.00,3.00,,0.00,Not paid\r\n'
|
||||
) % (
|
||||
regie.pk,
|
||||
invoice3.created_at.strftime('%y-%m'),
|
||||
|
|
Loading…
Reference in New Issue