Zum Inhalt springen
Odoo Menü
  • Anmelden
  • Jetzt gratis testen
  • Apps
    Finanzen
    • Buchhaltung
    • Rechnungsstellung
    • Spesenabrechnung
    • Tabellenkalkulation (BI)
    • Dokumente
    • E-Signatur
    Vertrieb
    • CRM
    • Vertrieb
    • Kassensystem – Shop
    • Kassensystem – Restaurant
    • Abonnements
    • Vermietung
    Websites
    • Website-Builder
    • E-Commerce
    • Blog
    • Forum
    • Livechat
    • E-Learning
    Lieferkette
    • Lager
    • Fertigung
    • PLM
    • Einkauf
    • Wartung
    • Qualität
    Personalwesen
    • Mitarbeiter
    • Personalbeschaffung
    • Abwesenheiten
    • Mitarbeiterbeurteilung
    • Personalempfehlungen
    • Fuhrpark
    Marketing
    • Social Marketing
    • E-Mail-Marketing
    • SMS-Marketing
    • Veranstaltungen
    • Marketing-Automatisierung
    • Umfragen
    Dienstleistungen
    • Projekte
    • Zeiterfassung
    • Außendienst
    • Kundendienst
    • Planung
    • Termine
    Produktivität
    • Dialog
    • Genehmigungen
    • IoT
    • VoIP
    • Wissensdatenbank
    • WhatsApp
    Apps von Drittanbietern Odoo Studio Odoo Cloud-Plattform
  • Branchen
    Einzelhandel
    • Buchladen
    • Kleidergeschäft
    • Möbelhaus
    • Lebensmittelgeschäft
    • Baumarkt
    • Spielwarengeschäft
    Essen & Gastgewerbe
    • Bar und Kneipe
    • Restaurant
    • Fast Food
    • Gästehaus
    • Getränkehändler
    • Hotel
    Immobilien
    • Immobilienagentur
    • Architekturbüro
    • Baugewerbe
    • Immobilienverwaltung
    • Gartenarbeit
    • Eigentümervereinigung
    Beratung
    • Buchhaltungsfirma
    • Odoo-Partner
    • Marketingagentur
    • Anwaltskanzlei
    • Talentakquise
    • Prüfung & Zertifizierung
    Fertigung
    • Textil
    • Metall
    • Möbel
    • Speisen
    • Brauerei
    • Firmengeschenke
    Gesundheit & Fitness
    • Sportklub
    • Brillengeschäft
    • Fitnessstudio
    • Therapeut
    • Apotheke
    • Friseursalon
    Handel
    • Handyman
    • IT-Hardware & -Support
    • Solarenergiesysteme
    • Schuster
    • Reinigungsdienstleistungen
    • HLK-Dienstleistungen
    Sonstiges
    • Gemeinnützige Organisation
    • Umweltschutzagentur
    • Plakatwandvermietung
    • Fotostudio
    • Fahrrad-Leasing
    • Software-Händler
    Alle Branchen ansehen
  • Community
    Lernen
    • Tutorials
    • Dokumentation
    • Zertifizierungen
    • Schulung
    • Blog
    • Podcast
    Bildung fördern
    • Bildungsprogramm
    • Scale-Up! Planspiel
    • Odoo besuchen
    Software anfragen
    • Herunterladen
    • Editionen vergleichen
    • Releases
    Zusammenarbeiten
    • Github
    • Forum
    • Veranstaltungen
    • Übersetzungen
    • Partner werden
    • Dienstleistungen für Partner
    • Buchhaltungsfirma registrieren
    Services anfragen
    • Partner finden
    • Buchhalter finden
    • Einen Experten treffen
    • Implementierungsservices
    • Kundenreferenzen
    • Support
    • Upgrades
    Github Youtube Twitter Linkedin Instagram Facebook Spotify
    +1 (650) 691-3277
    Eine Demo erhalten
  • Preiskalkulation
  • Hilfe

Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:

  • CRM
  • e-Commerce
  • Buchhaltung
  • Lager
  • PoS
  • Projekte
  • MRP
All apps
Sie müssen registriert sein, um mit der Community zu interagieren.
Alle Beiträge Personen Abzeichen
Stichwörter (Alle anzeigen)
odoo accounting v14 pos v15
Über dieses Forum
Sie müssen registriert sein, um mit der Community zu interagieren.
Alle Beiträge Personen Abzeichen
Stichwörter (Alle anzeigen)
odoo accounting v14 pos v15
Über dieses Forum
Hilfe

Header and footer not showing in PDF

Abonnieren

Erhalten Sie eine Benachrichtigung, wenn es eine Aktivität zu diesem Beitrag gibt

Diese Frage wurde gekennzeichnet
pdfinvoicev14
11 Antworten
33992 Ansichten
Avatar
Fernanda P

Hello! I am using 14.0 CE and I have a problem with the invoice PDF, the header and the footer with the company info are not showing, I searched and found that could be a problem with the wkhtmltopdf version but I installed multiple versions and still not working, also I search the document template and the template has the header and footer, I don't know why the PDF don't show the header and footer. 

Thanks for the help!

1
Avatar
Verwerfen
Avatar
ORLANDO M GUZMAN
Beste Antwort

SOLUTION TO HAVE PRINT HEADERS:

I had the same issue, and I was able to resolve it by following shaneebkhan's steps but in this way

The steps are as follows (ChatGPT assisted us with this):

  1. Install wkhtmltopdf on Ubuntu 22: To install wkhtmltopdf on Ubuntu 22, open a terminal and execute the following command:

    sudo apt install wkhtmltopdf
    
  2. Check the current version of wkhtmltopdf: After installation, verify the current version of wkhtmltopdf with the following command:

    wkhtmltopdf --version
    

    If the version is 0.12.6, you will need to remove it and download version 0.12.5.

  3. Uninstall version 0.12.6: Open a terminal and execute the following command to uninstall the current version of wkhtmltopdf (0.12.6):

    sudo apt remove wkhtmltopdf
    

    Then, if you wish, you can remove unused dependencies with the command:

    sudo apt autoremove
    
  4. Download and install version 0.12.5: Download the deb package of wkhtmltopdf version 0.12.5 with the following command (make sure to copy the entire command):

    wget https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/0.12.5/wkhtmltox_0.12.5-1.bionic_amd64.deb
    

    Next, install the downloaded package along with the required fonts:

    sudo dpkg -i wkhtmltox_0.12.5-1.bionic_amd64.deb
    sudo apt-get install xfonts-75dpi
    sudo apt-get update
    
  5. Fix broken packages (if necessary): If, after following the previous steps, you encounter broken packages, you can try to fix them with the following command:

    sudo apt --fix-broken install
    

Once you have followed these steps, verify the wkhtmltopdf version again to confirm that you are now using version 0.12.5 with the following command:

wkhtmltopdf --version

It should display version 0.12.5 if everything went well.

I hope this guide helps you resolve the wkhtmltopdf installation issues and generate reports correctly in Odoo 16. Good luck!

AS A RECOMMENDATION, some cases may require the installation of libssl1.1 to address additional issues. You can try downloading and installing it with the following commands:

wget http://archive.ubuntu.com/ubuntu/pool/main/o/openssl/libssl1.1_1.1.1-1ubuntu2.1~18.04.22_amd64.deb
sudo dpkg -i libssl1.1_1.1.1-1ubuntu2.1~18.04.22_amd64.deb


10
Avatar
Verwerfen
Jaime Pedraza

I had to validate the version directly on the /usr/local/bin folder, but it worked!

Avatar
Bernard Wilmus
Beste Antwort

Hi,

The solution of adding key/value in the system parameters solves a different issue: your report prints without any formating (CSS).

If your reports print without the header and the footer, check the log (error_level = debug). You will certainly view such messages:

WARNING databasename odoo.addons.base.models.ir_actions_report: wkhtmltopdf: b"The switch --header-spacing, is not support using unpatched qt, and will be ignored.The switch --header-html, is not support using unpatched qt, and will be ignored.The switch --footer-html, is not support using unpatched qt, and will be ignored.QStandardPaths: XDG_RUNTIME_DIR not set, defaulting to '/tmp/runtime-odoo16'\n"

To solve the problem you have to patch your wkhtml2pdf

Type this command to get the current version

# wkhtmltopdf --version
wkhtmltopdf 0.12.5

After patching your library, you will get the following response

# wkhtmltopdf --version
wkhtmltopdf 0.12.5 (with patched qt)

This will solve the problem.





1
Avatar
Verwerfen
Avatar
shaneebkhan
Beste Antwort

hi, 

hear the problem was installation of wkhtmltopdf 

i have same issue in odoo 16 finally i corrected by proper installation of wkhtmltopdf

first we have to install wkhtmltopdf ubuntu 22 terminal

      1.    apt install wkhtmltopdf

      2. wkhtmltopdf --version 

      whether its 0.12.6 remove and download 0.12.5

      3.wget https://github\\.com/wkhtmltopdf/wkhtmltopdf/releases/download/0\\.12\\.5/wkhtmltox_0\\.12\\.5\\-1\\.bionic_amd64\\.deb

     \\ 4\\.sudo\\ dpkg\\ \\-i\\ \\ wkhtmltox_0\\.12\\.5\\-1\\.bionic_amd64\\.deb

sometimes\\ it\\ may\\ error\\ then\\ try\\ to\\ install\\ one\\ or\\ two\\ things 

    \\ 1\\.wget\\ http://archive\\.ubuntu\\.com/ubuntu/pool/main/o/openssl/libssl1\\.1_1\\.1\\.1\\-1ubuntu2\\.1\\~18\\.04\\.22_amd64\\.deb

   \\ 2\\.sudo\\ dpkg\\ \\-i\\ libssl1.1_1.1.1-1ubuntu2.1~18.04.22_amd64.deb

    3.sudo apt-get install xfonts-75dpi

    4.sudo apt-get update

    5.apt --fix-broken install


finally confirm  the "wkhtmltopdf version is  0.12.5"

1
Avatar
Verwerfen
Avatar
jaydeep chaudhari
Beste Antwort

https://chatgpt.com/share/66e43fe4-d920-8003-a3e9-8b804f177c9a   try this i faced all error solve in this gpt

0
Avatar
Verwerfen
Avatar
Munjata KEITA
Beste Antwort

I had the same issue with Odoo 16 on Ubuntu 22.04 (arm64). 

I directly download the qt-patched version 0.12.6.1-2 on https://wkhtmltopdf.org/downloads.html


0
Avatar
Verwerfen
Avatar
valentierr@tuta.io
Beste Antwort

Wkhtmltopdf version 0.12.5 is not available for Ubuntu 22 arm64. Any hints to have headers and footers back for this architecture?

0
Avatar
Verwerfen
Munjata KEITA

Yes indeed, I had the same issue with arm64.
You can download it directly on https://github.com/wkhtmltopdf/packaging/releases/download/0.12.6.1-2/wkhtmltox_0.12.6.1-2.jammy_arm64.deb

Avatar
Tom Kaiser
Beste Antwort

Has anyone managed to get this working correctly?

I've tried setting the parameter.

All versions of wkhtmltopdf 0.12.6, 0.12.5, 0.12.5 (with patched qt).

All headers are being forwarded as well.

0
Avatar
Verwerfen
Avatar
Trịnh Văn Quang
Beste Antwort

I had the same issue when generating PDF reports for customers. I tried downgrading wkhtmltopdf to version 0.12.5, but it didn't work. 

However, I found the solution to fix it for both versions 0.12.6 and 0.12.5.


My solution was to update the system's proxy. 
Always redirect to HTTPS if you're using HTTPS. 
And set the following values in the header:


```

proxy_set_header Host $host;

proxy_set_header X-Real-IP $remote_addr;

proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;

proxy_set_header X-Forwarded-Proto https;

proxy_set_header X-Forwarded-Host $host;

```


You can refer to the template below.

0
Avatar
Verwerfen
Trịnh Văn Quang

map $http_upgrade $connection_upgrade {
default upgrade;
'' close;
}

upstream odoo_servers {
server 127.0.0.1:8069;
keepalive 16;
}
upstream odoo_chat_servers {
server 127.0.0.1:8072;
}

server {
listen 80;
server_name xxx-xxxx.demo.com;
if ($http_x_forwarded_proto != "https") {
return 301 https://$host$request_uri;
}

access_log /var/log/nginx/xxx-xxxx.demo.com.access.log;
error_log /var/log/nginx/xxx-xxxx.demo.com.error.log;

client_max_body_size 5000M;
proxy_max_temp_file_size 5000M;
proxy_connect_timeout 120s;
proxy_send_timeout 3600;
proxy_read_timeout 3600;

location / {
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto https;
proxy_set_header X-Forwarded-Host $host;

proxy_pass http://odoo_servers;
proxy_http_version 1.1;
}
location /longpolling {
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto https;
proxy_set_header X-Forwarded-Host $host;

proxy_pass http://odoo_chat_servers;
proxy_http_version 1.1;

}
location ~* /web/static/ {
proxy_cache_valid 200 60m;
proxy_buffering on;
expires 864000;
proxy_pass http://odoo_servers;
}

# common gzip
gzip_types text/css text/less text/plain text/xml application/xml application/json application/javascript;
gzip on;
}

Avatar
Israr
Beste Antwort

please check the odoo log to see if there is --no-header or --no-footer in the record so please uninstall your wkhtmlopdf and reinstall the latest one which is suitable for your os 

thanks

0
Avatar
Verwerfen
Avatar
Kiran K
Beste Antwort

Hi  Fernanda,

Try adding this record in Settings > Technical > Parameters  > System Parameters

key: report.url

value: your_ip:port

https://www.youtube.com/watch?v=lC9p_QJUW1Q


0
Avatar
Verwerfen
Fernanda P
Autor

Thanks for the answer, but I tried your solution and the video and still not working

Kiran K

Can you change the report type to HTML and check, might be some issues with the paper format in PDF

Avatar
shubham shiroya
Beste Antwort

If you are experiencing issues with the header and footer not showing in the invoice PDF in Odoo 14.0 Community Edition, here are a few steps you can take to troubleshoot and resolve the problem:

  1. Check the PDF settings in the company configuration:

    • Go to "Settings" -> "Companies" -> Select your company.
    • In the "Accounting" tab, make sure the "Header" and "Footer" options are enabled.
    • Save the changes and generate a new invoice PDF to see if the header and footer are now visible.
  2. Verify the document template:

    • Navigate to "Accounting" -> "Configuration" -> "Documents" -> "Document Templates".
    • Search for the template used for the invoice report.
    • Open the template and ensure that the header and footer are defined correctly.
    • Verify that the template includes the necessary variables and expressions to display the company information.
  3. Check the installed wkhtmltopdf version:

    • Ensure that you have the correct version of wkhtmltopdf installed and configured for your Odoo instance.
    • The recommended version for Odoo 14 is wkhtmltopdf 0.12.5. You can download it from the official website: https://wkhtmltopdf.org/downloads.html
    • After installation, restart your Odoo server to apply the changes.
  4. Test with different PDF formats:

    • In the company configuration, try changing the PDF format (e.g., from A4 to Letter) and regenerate the invoice PDF to see if the header and footer appear in a different format.
  5. Check server logs:

    • Monitor the server logs for any error messages related to generating the PDF. Look for any warnings or errors related to wkhtmltopdf.
    • Check if there are any permission issues with the Odoo process accessing the wkhtmltopdf executable.

If the above steps do not resolve the issue, you may need to dig deeper into the configuration and template files to identify the cause. Additionally, you can seek assistance from the Odoo community or consider reaching out to Odoo support for further help in troubleshooting and resolving the specific issue you are facing.

0
Avatar
Verwerfen
Diskutieren Sie gerne? Treten Sie bei, statt nur zu lesen!

Erstellen Sie heute ein Konto, um exklusive Funktionen zu nutzen und mit unserer tollen Community zu interagieren!

Registrieren
Verknüpfte Beiträge Antworten Ansichten Aktivität
No company data in PDF invoice?
pdf invoice v14
Avatar
0
Apr. 22
857
Can not print/preview account report (invoice) Gelöst
pdf invoice report v14
Avatar
1
März 22
4323
PDF Invoice line overflow
pdf invoice
Avatar
Avatar
Avatar
2
Juli 25
1532
Quote PDF Spacing & Layout
pdf invoice
Avatar
Avatar
1
Aug. 25
2091
How to apply a customized invoice pdf to an email template
pdf invoice
Avatar
Avatar
1
Juni 24
3290
Community
  • Tutorials
  • Dokumentation
  • Forum
Open Source
  • Herunterladen
  • Github
  • Runbot
  • Übersetzungen
Dienstleistungen
  • Odoo.sh-Hosting
  • Support
  • Upgrade
  • Individuelle Entwicklungen
  • Ausbildung
  • Buchhalter finden
  • Partner finden
  • Partner werden
Über uns
  • Unsere Firma
  • Markenwerte
  • Kontakt
  • Karriere
  • Veranstaltungen
  • Podcast
  • Blog
  • Kunden
  • Rechtliches • Datenschutz
  • Sicherheit
الْعَرَبيّة Català 简体中文 繁體中文 (台灣) Čeština Dansk Nederlands English Suomi Français Deutsch हिंदी Bahasa Indonesia Italiano 日本語 한국어 (KR) Lietuvių kalba Język polski Português (BR) română русский язык Slovenský jazyk slovenščina Español (América Latina) Español ภาษาไทย Türkçe українська Tiếng Việt

Odoo ist eine Suite von Open-Source-Betriebsanwendungen, die alle Bedürfnisse Ihres Unternehmens abdecken: CRM, E-Commerce, Buchhaltung, Lager, Kassensystem, Projektmanagement etc.

Das einzigartige Wertversprechen von Odoo ist, dass es gleichzeitig sehr einfach zu bedienen und voll integriert ist.

Website made with

Odoo Experience on YouTube

1. Use the live chat to ask your questions.
2. The operator answers within a few minutes.

Live support on Youtube
Watch now