I implemented a REST API on odoo using a controller. the API receives the contact id which I need to use to open the main contact page. I tried with request.redirect but it doesn't work "request.redirect("http://127.0.0.1:8069/web#id=26&cids=1&menu_id=338&action=475&model=res.partner&view_type=form") Thanks in advance.
Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:
- CRM
- e-Commerce
- Boekhouding
- Voorraad
- PoS
- Project
- MRP
Deze vraag is gerapporteerd
Hello VOIP_CRM,
You can redirect to contact page from odoo controller.
Find Example in comment.
I hope this will help you.
Thanks & Regards,
Email: odoo@aktivsoftware.com
Skype: kalpeshmaheshwari
For Example -
def get_contact_url(self):
"""This method will return url"""
action_id = self.env.ref('contacts.Your_template_id')
url = self.env['ir.config_parameter'].sudo().get_param('web.base.url')
contact_url = '/web#id=%s' % (self.id) + '&action=%s' % (action_id.id) + '&model=res.partner&view_type=form'
return url + contact_url
Geniet je van het gesprek? Blijf niet alleen lezen, doe ook mee!
Maak vandaag nog een account aan om te profiteren van exclusieve functies en deel uit te maken van onze geweldige community!
Aanmelden