Custom print format

Hi,

I want to print GL entries created by document that created, so im wondering if there any ways i can get list of GL Entry that assosiated with a voucher ?
i think i cant use get_doc , but i cant use get_list too because i cant get any example to use get_list with where clause

please advise

thanks

Why are you not using “General Ledger” report? It also have a default print format. If you want, you can create a new customized print format as well. But writing complicated logic in jinja is a bad idea, the language is not optimized for that.

Hi,

Here is my case, we need to print the GL because for every changes in GL we need to print it to archive it and later is need to be given to the tax collector as attached document, so we will print every changes in GL and then makes the accountant sign it so they will know all the changes in GL
actually i found this proses is not good and quite complicated but, whatever i said they said they must do this for their data and their tax report
thats why i want to add this as print format

any idea how i can do this?
or i should add a button that will generate this ?.. but how a button can refer to a print format because i think (at least so far i understand) that 1 doctype can only have 1 html as their print format, and for this case sales order and PO and JV , STE ,etc all predefined module have it

Thanks

duplicate of https://discuss.frappe.io/t/custom-print-format-error/4260/4