Skip to Content
Menú
This question has been flagged
2 Respostes
3373 Vistes

Hi everyone,

I have set up a Marketing Automation Campaign that follows up with customer quotations.

I want to be able to include a link to their SO, but I don't know how to add a dynamic link for this.

Can anyone please supply the coding logic for it?

Avatar
Descartar
Best Answer

Hi,To add a dynamic URL parameter within an email template follow these steps:1. Open the email template you wish to modify.
2. Choose the link where you want to include the dynamic URL parameter.
3. Click the "Insert/Edit Link" or "Insert/Edit Button" button in the email editor toolbar.
4. Enter the base URL, including any static parameters, in the URL field.
5. Append the dynamic URL parameter to the end of the URL, utilizing Odoo's expression syntax "{{...}}".
6. Save the updated email template.
Here's an example of adding a dynamic URL parameter to a link in an email template:

<a href="https://yourdomain.com/sales/orders/%7B%7Bobject.sale_order_id.id%7D%7D" target="_blank">https://yourdomain.com/sales/orders/{{object.sale_order_id.id}}">Click here to view your Sales Order</a>



Ensure the syntax and field names align with your specific use case, referring to Odoo documentation.


Hope it helps


Avatar
Descartar
Autor

Hi Cybrosys, I have tried remaking the URL but it is going to a 404 Page on my site:

https://capitalequipment.com.au/sales/orders/{{ object.sale_order_id.id}}

Can you help troubleshoot please?

The Double Bracket Syntax doesn't work in my version Odoo 17. When using them in email template links the resulting link contains %7b%7bobject.sale_order_id.id%7D%7D instead of the desired object id. Any advice on what I am doing wrong?

Autor

Hi David,
CandidRoot Solutions helped me set this up in my system, I recommend reaching out to them for support.

Autor Best Answer

Thank you so much Cybrosys! What if the URL has a unique access token, does that impact the URL at all?

Avatar
Descartar
Related Posts Respostes Vistes Activitat
4
d’oct. 22
5640
0
de jul. 21
32
1
d’oct. 20
4501
6
d’ag. 25
41829
1
de des. 23
2601