Pular para o conteúdo
Menu
Esta pergunta foi sinalizada
2 Respostas
9200 Visualizações

Heello everybody!!

Need an answer please.

Why doesnt it change anything when i add a css file and call it like this in the xml file:

   <link rel="stylesheet" href="/module_namel/static/src/css/file_name.css" />

Help pleaase

Avatar
Cancelar

need to be added in an asset. and update the module to refresh the view.

Melhor resposta

Hi, below this code is helpful for you.

#view file:

<template id="my_assets_id" name="website assets for my module" inherit_id="website.theme">        <xpath expr="." position="inside">        <link rel="stylesheet" href="/website_my_module/static/src/css/my.css"/>        </xpath>    </template>

# __openerp__.py
 {
     'name': "CSS Example",
     'description': "new css example",
     'category': 'Generic Modules/Others',
     'depends': ['web'],
     'data': [],
     'css': ['static/src/css/my_css.css'],
 }
Avatar
Cancelar
Publicações relacionadas Respostas Visualizações Atividade
0
dez. 20
6234
2
mai. 20
7400
0
jun. 18
5639
0
set. 17
4698
0
jul. 15
6409