Skip to Content
Menu
This question has been flagged
2619 Views

i hava a model like this hav 1 fileld

class customer_number(models.Model):
    _inherit = "res.partner"

    customer_number= fields.Char(string='Custom Number')

how to get that data each user login website and put to xml file

<?xml version="1.0" encoding="utf-8"?>
<odoo>
    <data>
        <template id="custom_number" inherit_id="web._assets_primary_variables" name="Website Login Layout" priority="20">
            <xpath expr="//link[last()]" poision="after">
                <t t-if="customer_number==0">
                    <link rel="stylesheet" type="text/scss" href="/customer_number/statis/css/custom_variables_bla.scss"/>
                </t>
                <t t-if="customer_number==1">
                    <link rel="stylesheet" type="text/scss" href="/customer_number/statis/css/custom_variables_blu.scss"/>
                </t>
            </xpath>
        </template>
    </data>
</odoo>
Avatar
Discard
Related Posts Replies Views Activity
2
Dec 23
11087
3
Jul 22
20954
2
Jun 21
16960
0
May 16
2893
1
Aug 15
8287