Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- -
- In order to test the PDF reports defined on an invoice, we will print an Invoice Report
- -
- !python {model: account.invoice}: |
- import netsvc, tools, os
- (data, format) = netsvc.LocalService('report.account.invoice.counter3').create(cr, uid, [ref('account.account_invoice_customer0')], {}, {})
- if tools.config['test_report_directory']:
- file(os.path.join(tools.config['test_report_directory'], 'account-invoice-hu.'+format), 'wb+').write(data)
Advertisement
Add Comment
Please, Sign In to add comment