Pular para o conteúdo
Menu
Esta pergunta foi sinalizada
1 Responder
4774 Visualizações

Hi Everyone,

I need a solution to get current URL in openerp v7. I paste my code hear,if anyone knows please reply.

from openerp.http import request

url = request.httprequest.environ['HTTP_REFERER']

It throws error like ImportError: No module named http

Avatar
Cancelar
Melhor resposta

Hi

current_url = self.env['ir.config_parameter'].sudo().get_param('web.base.url')

Use the above code to get current URL in python.
Hope this may help you.

Avatar
Cancelar
Publicações relacionadas Respostas Visualizações Atividade
1
ago. 25
595
0
out. 22
595
4
fev. 24
8616
3
dez. 19
5344
0
mar. 24
10107