Odoo Help


how to set div in the bottom of the last page in a qweb report?

Jesús Ventosinos
on 2/5/15, 1:55 PM 1,937 views

how i can put a div in the bottom of the last page of a qweb pdf report?


Anil R. Kesariya

--Anil R. Kesariya--
| 6 5 8
Gandhinagar, India
--Anil R. Kesariya--
ERP Consultant

Key Skill
Technical & Functional Expert
Anil R. Kesariya
On 5/18/15, 1:37 AM

Hi Jesús Ventosinos,

This is doable in QWEB report too!

You have to extend (Override) subset function which is defined in 'report' module.

You have to add piece of code inside the subset function : static/src/js/subst.js

var operations = {

'bottom-page': function (elt) { elt.style.visibility = (vars.page === vars.topage) ? "visible" : "hidden"; },


for (var klass in operations) {

var y = document.getElementsByClassName(klass);

for (var j=0; j<y.length; ++j) operations[klass](y[j]);


<div class="bottom-page">

This content will dislpay only in last page.. now you can add this div where you want.. header ,body or footer it will display on last page only.


Hope this will helps.





| 6 4 7
Lodz, Poland

On 2/5/15, 3:24 PM

This is a problem that is difficult to resolve, see similar post

Your Answer

Please try to give a substantial answer. If you wanted to comment on the question or answer, just use the commenting tool. Please remember that you can always revise your answers - no need to answer the same question twice. Also, please don't forget to vote - it really helps to select the best questions and answers!

About This Community

This platform is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.


Odoo Training Center

Access to our E-learning platform and experience all Odoo Apps through learning videos, exercises and Quizz.

Test it now

Question tools

2 follower(s)


Asked: 2/5/15, 1:55 PM
Seen: 1937 times
Last updated: 3/28/16, 4:26 PM