ERPNext Conference 2019* Blog

Print issue {{ frappe.db.get_value("Customer", doc.customer, "tax_id") }}


i using
TRN#: {{ frappe.db.get_value(“Customer”, doc.customer, “tax_id”) }}
Customer#:{{ frappe.db.get_value(“Customer”, doc.customer, “customer_code”) }}

They are displaying in erpnext like

But when i output pdf, these two fields display “None”

How to make the value can be displayed in pdf.

My system is:
ERPNext: v11.1.44 (master)
Frappe Framework: v11.1.39 (master)


Try this …
edit the site_config.json, and add the static IP address of your local server.

“host_name”: “
then do a bench restart


thank you for your reply.
Now in my site_config.json
“host_name”: “”,

so now if i change to static IP,like

Is there any other problem happen?


i did two trials:
“host_name”: “http://localhost”,
“host_name”: “”,

the same problem, in erpnext, ok, but display “none” in pdf.


You need to adjust the IP address to match your requirements - I just used as an example


i think i using http://localhost is the same function as static ip, right?
Now localhost is not working for solving this issue.


If you have an entry in the /etc/hosts file that matches the IP of your machine, then it should also work, so like this (but change the xxx to match the actual IP) localhost


now in my /etc/hosts: manchemical localhost

So i need to add, or change manchemical?


Now I add 167.xx.68.6
So it looks like: manchemical localhost

167.xx.68.6 is my server ip.


but still display “none” in pdf.


just now even i change
“host_name”: “https://167.xx.68.6” in site_config.json
and bench restart.

Still “none” in pdf.

sorry, i am fresh in erpnext, and appreciated to help me, please help me to solve this issue!


Did you create a report builder version, or is this a Jinja2 output?


i dont know, i installed original erpnext.