跳至内容
菜单
此问题已终结
1258 查看

hi, how can add a custom background for my qweb template?

i have that but show me empty, in this case, i only want to set background in the second page


<template id="report_template_xxx">

            <t t-call="web.html_container">

                <t t-foreach="docs" t-as="o">

                    <meta charset="UTF-8" />

                    <div class="page" t-attf-class="article o_report_layout_standard o_company_#{o.company.id}_layout {{  'o_report_layout_background' if o.company.layout_background in ['Geometric', 'Custom']  else  '' }}"  t-att-data-oe-model="o and o._name" t-att-data-oe-id="o and o.id" t-att-data-oe-lang="o and o.env.context.get('lang')">

                        <span>background</span>

                    </div>

                    <div class="page" st-att-style="'background-image: url(/xxxx/static/img/Imagen1.png); background-size: cover; background-repeat: no-repeat; background-position: center; page-break-before: always;'">

                        <span>background 2</span>

                    </div>

                </t>

            </t>

        </template>

形象
丢弃
相关帖文 回复 查看 活动
2
2月 25
1794
1
1月 19
8770
0
12月 24
1085
2
2月 25
1377
0
8月 24
1657