Fetching name of creator, submittor, approvar of doc in print

we want to show the name of persons who has created & submitted doc (for eg. Invoice/Delivery Note) print Format.

If it is to be done through some custom field, what type of field to be used and how?

1 Like

Full name or email id.

Email id is easy enough use {{ doc.owner }} for creator and {{ doc.modified_by }} for modified.

1 Like

As we need to show the same in official document, we need to show full
name. Kindly advise.

Thanking you,

With Regards,
Deven Shah
Safeworld Systems Pvt Ltd
M - 09825060116

{{ frappe.get_fullname(doc.owner) }}
2 Likes

I tried adding this. But, it’s showing following error.

Share your trace not screenshot!

Trace means? Screencast?

Just paste the complete text here and wrap it in ```

Traceback (innermost last):
File β€œ/home/frappe/press/benches/1511060614/apps/frappe/frappe/app.py”, line 67, in application
response = frappe.handler.handle()
File β€œ/home/frappe/press/benches/1511060614/apps/frappe/frappe/handler.py”, line 75, in handle
execute_cmd(cmd)
File β€œ/home/frappe/press/benches/1511060614/apps/frappe/frappe/handler.py”, line 109, in execute_cmd
ret = frappe.call(method, **frappe.form_dict)
File β€œ/home/frappe/press/benches/1511060614/apps/frappe/frappe/init.py”, line 777, in call
return fn(*args, **newargs)
File β€œ/home/frappe/press/benches/1511060614/apps/frappe/frappe/templates/pages/print.py”, line 139, in get_html_and_style
no_letterhead=no_letterhead, trigger_print=trigger_print),
File β€œ/home/frappe/press/benches/1511060614/apps/frappe/frappe/templates/pages/print.py”, line 118, in get_html
html = template.render(args, filters={β€œlen”: len})
File β€œ/home/frappe/press/benches/1511060614/env/lib/python2.7/site-packages/jinja2/environment.py”, line 989, in render
return self.environment.handle_exception(exc_info, True)
File β€œ/home/frappe/press/benches/1511060614/env/lib/python2.7/site-packages/jinja2/environment.py”, line 754, in handle_exception
reraise(exc_type, exc_value, tb)
File β€œβ€, line 1, in template
TemplateSyntaxError: unexpected β€˜<’

There seems to be a syntax error in your template.

Hi there,
I have same requirement, I want to show names of approvers for the workflow in print format?
How I can do that?

for Workflow approver, you need to do some customisation, you can get approver name from comments. Comments are stored in Communication doctype.

@kolate_sambhaji Thanks for your answer, but how to know the approver and the status of the workflow stage in each level?

Where do i add this line ? please suggest.

{{frappe.get_fullname(doc.owner)}}

It’s Work 100%

1 Like

Hi Sir,
Where to add these lines to get the name?
Suppose, I want it for purchase order because I am using workflow for purchase order approval. Please help me?

Did you manage?