ERPNext.com Frappe Cloud Support Partners Foundation Frappe School

Barcode on Sales Invoice with Invoice number

I would like to print a barcode containing the invoice number (doc.name) on all invoices. I was successfully able to add the barcode field. But have no clue how to automatically fetch doc.name into the barcode.

We maintain a scanned copy of invoices signed and sealed by our customers. If there is a barcode on the invoice it can automatically be organized or renamed at the time of scanning using any OCR.