Community mailing list archives

community@mail.odoo.com

Re: A Qweb question

by
zahid
- 08/26/2016 06:18:21
Hi  @Dominique
if you mean by align on top = make the image the highest possible, you can simply adjust top margin by either :
- you change paper format margins  in /report/data/report_paperformat.xml
   set the field  <field name="margin_top">25</field>  to your choice.

- In layout xml file   in  /report/views/layout.xml , look for the header section , then adjust css margin propreties as you like
  
  <template id="external_layout_header">
    <div class="header">
        <div class="row">
            <div class="col-xs-8 col-xs-offset-2">
                <img t-if="company.logo" t-att-src="'data:image/png;base64,%s' % company.logo" style="max-height: 120px;"/>
            </div>
        </div>
    </div>
</template>        



But this wil change and affect all your other reports.  So as @Semah suggests , creating a custom layout is more suitable.

rgrds


Odoo Integrator,
Data integration
BI and IT consulting.

j.zahid@auriumtechnologies.com
tél  0661360233 - 0636898882
fax 0528215738

On Fri, Aug 26, 2016 at 9:57 AM, Dominique KON SUN TACK <dominique.k@elico-corp.com.sg> wrote:
Thanks for replying, although that was not the question.

The link is about the inheritance mechanism for qweb - 
The question is about how to make an image align on the top, when the image is in the header.


Dominique KON-SUN-TACK 

On 26 August 2016 at 16:38, Semah Raddaoui <semeh.raddaoui@gmail.com> wrote:

Hello,

You can create a custom layout for your reports and call it in your report.
Check this subject https://www.odoo.com/forum/help-1/question/can-t-manage-to-use-a-custom-layout-in-odoo-8-98425

R.


On Aug 25, 2016 12:17, "Dominique KON SUN TACK" <dominique.k@elico-corp.com.sg> wrote:
Hi Guys,

I have been trying unsuccessfully to change change the header of qweb reports...

What I need to do, is to align on the top, the logo of the company, which appear on the header.

vertical-align:top or text-top does not work

Would anybody got a clue ?

Dominique KON-SUN-TACK

_______________________________________________
Mailing-List: https://www.odoo.com/groups/community-59
Post to: mailto:community@mail.odoo.com
Unsubscribe: https://www.odoo.com/groups?unsubscribe

_______________________________________________
Mailing-List: https://www.odoo.com/groups/community-59
Post to: mailto:community@mail.odoo.com
Unsubscribe: https://www.odoo.com/groups?unsubscribe


_______________________________________________
Mailing-List: https://www.odoo.com/groups/community-59
Post to: mailto:community@mail.odoo.com
Unsubscribe: https://www.odoo.com/groups?unsubscribe