Hi! Doew anyone know how can I add in Lead print format
the date of contact (I mean the date that the potential customer called me or send an email for contact)
address details
comment details
Tax ID
Thanks for any replay.
Nikoletta
Hi! Doew anyone know how can I add in Lead print format
the date of contact (I mean the date that the potential customer called me or send an email for contact)
address details
comment details
Tax ID
Thanks for any replay.
Nikoletta
You can use frappe.db.get_value("[doctype]", "[name]", "fieldname")
in print format to print values from another doctype.
Another method:
See this code, I have printed warehouse address in print format
{%- for row in doc.po_details|slice(1) -%}
{% set u = frappe.get_doc(""Warehouse"", row[0].warehouse) %}
<div class=""row"">
<div class=""col-xs-5 text-right""><label><b>Ship To</b></label></div>
<div class=""col-xs-7 ""> {{ u.warehouse_name or '' }} </div>
</div>
<div class=""row"">
<div class=""col-xs-5 text-right""></div>
<div class=""col-xs-7 ""> {{ u.address_line_1 or '' }} </div>
</div>
<div class=""row"">
<div class=""col-xs-5 text-right""></div>
<div class=""col-xs-7 ""> {{ u.address_line_2 or '' }} </div>
</div>
<div class=""row"">
<div class=""col-xs-5 text-right""></div>
<div class=""col-xs-7 ""> {{ u.city or '' }}, {{ u.state or '' }} {{ u.pin or '' }} </div>
</div>
{%- if u.phone_no -%}
<div class=""row"">
<div class=""col-xs-5 text-right""><label><b>Phone:</b></label></div>
<div class=""col-xs-7 ""> {{ u.phone_no or '' }} </div>
</div>
{%- endif -%}
{%- endfor -%}