ERPNext Foundation ERPNext Cloud User Manual Blog Discuss Frappé* Donate

How to customize Quotation print format

print_format

#1

Hello,

I need to customize quotation print format. By loading print format list page I could not find the template for Quotation so I think this cannot be modified.

Is there a way to copy that template as the starting point? I only need to modify a few elements.

Regards
Jaime


#2

As far as I know, you can’t modify the Standard Template via Print Format. But you can create a new Print Format for that document and modify what you want.
When you’ll print the document, you need to select the print format you have created (or set it as default)


#3

I tried doing that way few several months, but every time I wanted to make changes it was a struggle. Your best option is to create a jinja2 format (and maybe set that as the default).
My sample (for an invoice - but should be the same principles for any doc) with its output is shown here


#4

@mel_erp I know that, but you tell “modify what you want”. That’s the point. I want not to start all over again but with the current template.


#5

When you do a Print Format based on Quotation, it already loads the template. So you just have to add what you want.


#6

That’s not true.

Let me tell you the steps because perhaps you don’t understand what I need to accomplish:

  1. Load Print Format list page

  2. Search DocType: Quotation. Nothing is shown.

  3. Click “New” button

  4. Set “Name” field as “Cotización”

  5. Set checkbox “Custom Format”.

  6. HTML text area appears empty

On the last step, I need the HTML field to be loaded with the current template. From that point, I can change what I need to change.

Regards
Jaime


#7

Step 1: Create a new print format and save


Step 2: Edit Format

Step 3: Add/Drag and drop whatever you need from the left of the page (I guess you need the ‘Custom HTML’) and write the html/Jinja you need.
Step 4: Choose the print format when you print

That’s how you customise Quotation Print format.


#8

I think someting is still missing.

Your steps are for creating the HTML from scratch… I know how to do it, however, I need the current quotation format as the starting point in HTML format.

It is obvious I can just add several HTML tags or Jinja instructions in order to create the format, but I need to get the current quotation format in order to just modified.

Currently, if I have a quotation and then print it, ERPNext shows me the quotation. I need that HTML/Jinja instructions so that I can only modify a few elements, for example, typography.

Furthermore, without choosing custom HTML format I am able to edit the format using this page:

That is not what I am looking for… for example, no Bootstrap CSS is taken into account when modifying the header. On the other hand, I want just to add the company logo in the header… with that page, I don’t have a way to add it.

I hope this is finally clear now.

Regards

Jaime


#9

Finally I have created the HTML from scratch.

Regards
Jaime