Skip to Content
Odoo เมนู
  • ลงชื่อเข้าใช้
  • ทดลองใช้ฟรี
  • แอป
    การเงิน
    • ระบบบัญชี
    • ระบบการออกใบแจ้งหนี้
    • ระบบบัญชีรายจ่าย
    • ระบบการจัดการข้อมูลผ่านสเปรดชีต (BI)
    • เอกสาร
    • ระบบลงลายเซ็น
    การขาย
    • ลูกค้าสัมพันธ์
    • การขาย
    • POS ร้านค้า
    • POS ร้านอาหาร
    • ระบบสมัครสมาชิก
    • การเช่า
    การจัดการเว็บไซต์
    • เครื่องมือสร้างเว็บไซต์
    • ระบบการขายออนไลน์
    • บล็อก
    • ฟอรั่ม
    • ไลฟ์แชท
    • ระบบการอบรมออนไลน์
    ซัพพลายเชน
    • คลังสินค้า
    • ระบบการผลิต
    • PLM
    • ระบบการจัดซื้อ
    • การซ่อมบำรุง
    • ระบบจัดการคุณภาพ
    ทรัพยากรบุคคล
    • ข้อมูลพนักงาน
    • ระบบสรรหาบุคลากร
    • ระบบการลา
    • การประเมิน
    • ระบบการแนะนำพนักงาน
    • ระบบจัดการยานพาหนะ
    การตลาด
    • โซเชียลมาร์เก็ตติ้ง
    • การตลาดผ่านอีเมล
    • ระบบการตลาดผ่าน SMS
    • ระบบการจัดงานอีเวนต์
    • การตลาดแบบอัตโนมัติ
    • ระบบแบบสำรวจ
    การบริการ
    • โปรเจกต์
    • ระบบบันทึกเวลา
    • ระบบการจัดการบริการภาคสนาม
    • ระบบดูแลช่วยเหลือ
    • การวางแผน
    • การนัดหมาย
    ประสิทธิผล
    • ระบบแสดงความคิดเห็น
    • ระบบการอนุมัติ
    • ไอโอที
    • VoIP
    • คลังข้อมูล
    • WhatsApp
    แอปพลิเคชันของบุคคลที่สาม Odoo สตูดิโอ แพลตฟอร์มคลาวด์ของ Odoo
  • อุตสาหกรรม
    การค้าปลีก
    • ร้านขายหนังสือ
    • ร้านขายเสื้อผ้า
    • ร้านขายเฟอร์นิเจอร์
    • ร้านขายของชำ
    • ร้านขายฮาร์ดแวร์
    • ร้านขายของเล่น
    Food & Hospitality
    • บาร์และผับ
    • ร้านอาหาร
    • อาหารฟาสต์ฟู้ด
    • Guest House
    • ตัวแทนจำหน่ายเครื่องดื่ม
    • Hotel
    Real Estate
    • Real Estate Agency
    • บริษัทสถาปัตยกรรม
    • บริษัทรับเหมา
    • การจัดการอสังหาริมทรัพย์
    • การจัดสวน
    • สมาคมเจ้าของอสังหาริมทรัพย์
    Consulting
    • Accounting Firm
    • Odoo พาร์ทเนอร์
    • เอเจนซี่การตลาด
    • สำนักงานกฎหมาย
    • บริการสรรหาบุคลากร
    • การตรวจสอบและการรับรอง
    ระบบการผลิต
    • Textile
    • Metal
    • Furnitures
    • Food
    • Brewery
    • ของขวัญขององค์กร
    สุขภาพ & ฟิตเนส
    • ชมรมกีฬา
    • ร้านขายแว่นตา
    • ฟิตเนส
    • ผู้ประกอบวิชาชีพด้านสุขภาพ
    • ร้านขายยา
    • ร้านทำผม
    Trades
    • ช่างซ่อม
    • ฮาร์ดแวร์และการสนับสนุนด้านไอที
    • Solar Energy Systems
    • ช่างทำรองเท้า
    • บริการทำความสะอาด
    • HVAC Services
    Others
    • Nonprofit Organization
    • สำนักงานสิ่งแวดล้อม
    • ร้านเช่าป้ายโฆษณา
    • การถ่ายภาพ
    • ร้านเช่าจักรยาน
    • ตัวแทนจำหน่ายซอฟต์แวร์
    Browse all Industries
  • คอมมูนิตี้
    ศึกษา
    • บทเรียน
    • เอกสารกำกับโปรแกรม
    • การรับรอง
    • การฝึกอบรม
    • บล็อก
    • พอดแคสต์
    เพิ่มศักยภาพให้กับการศึกษา
    • โปรแกรมการศึกษา
    • Scale Up! Business Game
    • เยี่ยมชม Odoo
    รับซอฟต์แวร์
    • ดาวน์โหลด
    • เปรียบเทียบรุ่น
    • เผยแพร่
    ทำงานร่วมกัน
    • Github
    • ฟอรั่ม
    • ระบบการจัดงานอีเวนต์
    • การแปล
    • ร่วมเป็นพาร์ทเนอร์
    • Services for Partners
    • ลงทะเบียนเพื่อสร้างบัญชีบริษัทของคุณ
    รับบริการ
    • ค้นหาพาร์ทเนอร์
    • ค้นหานักบัญชี
    • พบกับที่ปรึกษา
    • บริการติดตั้งระบบเพื่อใช้งาน
    • ข้อมูลอ้างอิงลูกค้า
    • การสนับสนุน
    • อัปเกรด
    Github Youtube Twitter Linkedin Instagram Facebook Spotify
    +1 (650) 691-3277
    รับการสาธิต
  • ราคา
  • ช่วยเหลือ

Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:

  • ลูกค้าสัมพันธ์
  • e-Commerce
  • ระบบบัญชี
  • สินค้าคงคลัง
  • PoS
  • โปรเจกต์
  • MRP
All apps
คุณต้องลงทะเบียนเพื่อโต้ตอบกับคอมมูนิตี้
All Posts คน เหรียญรางวัล
แท็ก (View all)
odoo accounting v14 pos v15
เกี่ยวกับฟอรั่มนี้
คุณต้องลงทะเบียนเพื่อโต้ตอบกับคอมมูนิตี้
All Posts คน เหรียญรางวัล
แท็ก (View all)
odoo accounting v14 pos v15
เกี่ยวกับฟอรั่มนี้
ช่วยเหลือ

Add dynamic url parameter in link or button in email odoo v16

ติดตาม

รับการแจ้งเตือนเมื่อมีกิจกรรมในโพสต์นี้

คำถามนี้ถูกตั้งค่าสถานะ
emailurldynamicodoo16features
9 ตอบกลับ
21757 มุมมอง
อวตาร
LAPA Zero-Pensieri

hi how i can add dynamic data in url of link or button in an email in the marketing campaign automation? 

0
อวตาร
ละทิ้ง
LAPA Zero-Pensieri
ผู้เขียน

the placeholder {{...}} not work is converted in entities

https://www.lapa.ch/offerta-guanciale?contact_name=%7B%7Bobject.name%7D%7D&phone=%7B%7Bobject.name%7D%7D&email=%7B%7Bobject.email%7D%7D&partner_name=%7B%7Bobject.parent_id.name%7D%7D

LAPA Zero-Pensieri
ผู้เขียน

i have try to use QWeb Template like

<a t-att-href="'https://www.lapa.ch/offerta-guanciale?contact_name=' + object.name + '&email='+ object.email +'&phone='+ object.phone +'&partner_name='+ object.parner_id.name"></a>

but for some reason the email return error

if i write just "'https://www.lapa.ch/offerta-guanciale?contact_name=' + object.name + '&email='+ object.email" work if i add phone not work... im confused.

@Cybrosys Techno Solutions Pvt.Ltd have some idea?

LAPA Zero-Pensieri
ผู้เขียน

i think the QWeb Template error is for object.phone is not escaped. how can i escape this value in the html of an email?

LAPA Zero-Pensieri
ผู้เขียน

for some reason i cant add more than 2 params. 2 parms work if i send manually the email or if i send a test but not work if the campaign start

return QWEB Template error when try to send automatically

อวตาร
Bhavin Patel
คำตอบที่ดีที่สุด

To add a dynamic URL parameter in a link or button in an email template in Odoo v16, you can use the following steps:

  1. Open the email template that you want to modify.
  2. Select the link or button that you want to add the dynamic URL parameter to.
  3. Click on the "Insert/Edit Link" or "Insert/Edit Button" button in the email editor toolbar.
  4. In the URL field, enter the base URL that you want to use for the link or button, including any static parameters.
  5. Add the dynamic URL parameter to the end of the URL, using the Odoo expression syntax "{{...}}".
  6. Inside the double curly braces, enter the name of the field or variable that you want to use as the dynamic URL parameter.
  7. Save the email template.

Here's an example of how you can add a dynamic URL parameter to a link in an email template:

Let's say you want to include a link to the customer portal for each recipient of your email. You can use the following URL as the base URL for the link:

https://yourdomain\.com/my/customers/portal/

To\ add\ a\ dynamic\ URL\ parameter\ for\ the\ customer\ ID,\ you\ can\ modify\ the\ URL\ like\ this:

https://yourdomain.com/my/customers/portal/?customer_id={{object.partner_id.id}}

In this example, we're using the Odoo expression "{{object.partner_id.id}}" to retrieve the ID of the customer associated with the email recipient. This will dynamically insert the customer ID into the URL for each recipient, so they will be directed to their own customer portal page when they click the link.

Note that the exact syntax and field names may vary depending on your specific use case, so you may need to consult the Odoo documentation or seek further assistance to ensure that your dynamic URL parameter is set up correctly.

2
อวตาร
ละทิ้ง
Emma Dimech

Hi, I am trying to follow these steps for the following:
> link to Quotion (portal view) from follow-up automated email in Marketing Automation App (Lead / Opportunity Model)
> link to Worsheet Report (portal view) from Invoice email template.
> link to Quotation (portal view) from follow-up automated email in Marketing Automation App (Sales Order Model)

I cannot seem to get the syntax right, can you provide any advice?

David Waters

I'd like to do the same but the steps mentioned here don't work. Like other answers in this thread, I also get %7B%7Bobject.partner_id.id%7D%7D as a resulting link whether I use ${ } format or {{ double brackets }} the result is the same. Has something changed in Odoo 17 that doesn't allow for this solution?

อวตาร
LAPA Zero-Pensieri
ผู้เขียน คำตอบที่ดีที่สุด

thx, but from marketing automation email i cant go into html of the email. im miss something? 

EDIT i have found the button for go inside the html of email but when the email is send the html {{ is convertend in html entities.. how can i solve this? 


is the result 
contact_name=%7B%7Bobject.name%7D%7D&phone=%7B%7Bobject.name%7D%7D&email=%7B%7Bobject.email%7D%7D&partner_name=%7B%7Bobject.parent_id.name%7D%7D

2
อวตาร
ละทิ้ง
David Waters

I'd like to do the same and I also get %7B%7Bobject.partner_id.id%7D%7D whether I use ${ } format or {{ double brackets }} the result is the same. Has something changed in Odoo 17 that doesn't allow for this solution?

อวตาร
Joe-Civ
คำตอบที่ดีที่สุด

@LAPA Zero, 

I'm trying to do the same thing, and here's the problem: 

There's two different types of email templates in Odoo

  1. Email marketing - these are used for mass mailings to your customer in the Email Marketing tool
  2. Mail templates - these are used for single emails for server triggered mailing (eg QWeb)

These aren't the same.  

Unfortunately, Email marketing doesn't support Jinja fields, and Mail Templates (like QWeb, don't support Jinja fields.  

Sorry, what your asking for isn't possible, even in today's Odoo online OOTB.  You would have to get a premium account with access to odoo_sh and customize it.  

0
อวตาร
ละทิ้ง
อวตาร
Tom Rubino
คำตอบที่ดีที่สุด

simply looking for a way to link to current record via the email template. 

This doesn't seem to work either. 

<div style="margin: 16px 0px 16px 0px;" data-oe-version="1.0">

    <a t-att-href="ctx.get('https://XXXXX.odoo.com/odoo/plm/2/action-1087/{{object.id}}')" style="color: #374151; border-style: none; margin: 0px; box-sizing: border-box; border-width: 0px; background-color: #875a7b; padding: 8px 16px; text-decoration: none; border-radius: 5px; font-size: 13px;"><font style="color: #ffffff;">

        Validate my account&nbsp;</font></a>

</div>

Anyone figure out how to create a dynamic link to a record in an email template? I'm in Odoo 18...

0
อวตาร
ละทิ้ง
อวตาร
Paulo Matos
คำตอบที่ดีที่สุด

Perhaps use a method to retrive the values you want?

In Odoo 18:

<t t-set="desired_value" t-value="object.your_method_retrieve_url()"/>

<a t-att-href='desired_value' t-out="desired_value" />

I solved my problem this way

Thanks

0
อวตาร
ละทิ้ง
อวตาร
Tom Jones
คำตอบที่ดีที่สุด

How is an issue posted about Odoo v16 stil a problem in v17

Did anyone figure it out?

0
อวตาร
ละทิ้ง
อวตาร
David Waters
คำตอบที่ดีที่สุด

First time User.. Can't delete this yet. I though I was commenting not answering... My bad.. 

I'd like to do the same and I also get %7B%7Bobject.partner_id.id%7D%7D whether I use ${ } format  or {{ double brackets }} the result is the same. Has something changed in Odoo 17 that doesn't allow for this solution?

0
อวตาร
ละทิ้ง
อวตาร
Maduka Sopulu
คำตอบที่ดีที่สุด

The way to achieve this is by going to the mail template, 

highlight the word / sentence you want to link, 

Click on the link option, and paste your link with the dynamic field props like  
${object.id}

e.g

/web#id=${object.id}&action=2401&model=approval.request&view_type=form&cids=&menu_id=1160

0
อวตาร
ละทิ้ง
อวตาร
Cybrosys Techno Solutions Pvt.Ltd
คำตอบที่ดีที่สุด

Hi,

In the email template, in 

<field name="body_html" type="html">

You can give any html content you want for the body of your email.

<div style="margin: 16px 0px 16px 0px;">
<a t-att-href="ctx.get('token_url')"
style="background-color: #875A7B; padding: 8px 16px 8px 16px; text-decoration: none; color: #fff; border-radius: 5px; font-size:13px;">
Validate my account
</a>
</div>

The above mentioned code is the button you see for the email sent when validating account. In the t-att-href, you can give the dynamic value you want.

Regards

0
อวตาร
ละทิ้ง
สนุกกับการพูดคุยนี้ใช่ไหม? เข้าร่วมเลย!

สร้างบัญชีวันนี้เพื่อเพลิดเพลินไปกับฟีเจอร์พิเศษและมีส่วนร่วมกับคอมมูนิตี้ที่ยอดเยี่ยมของเรา!

ลงชื่อ
Related Posts ตอบกลับ มุมมอง กิจกรรม
Forwarding emails to a specific Opportunity
email opportunity odoo16features
อวตาร
อวตาร
1
มี.ค. 25
3330
How can the user responsible for the task receive a personalized email?
email task dynamic
อวตาร
อวตาร
1
ธ.ค. 24
1736
Odoo Summary Mail - Change from Daily to Weekly แก้ไขแล้ว
email Summary odoo16features
อวตาร
อวตาร
อวตาร
2
ก.ค. 24
2862
v16: generate Lead / Opportunity using emails
email leads odoo16features
อวตาร
1
เม.ย. 24
2053
configure multiple email domains to send and receive emails
email helpdesk odoo16features
อวตาร
0
ก.ย. 24
2169
คอมมูนิตี้
  • บทเรียน
  • เอกสารกำกับโปรแกรม
  • ฟอรั่ม
โอเพนซอร์ส
  • ดาวน์โหลด
  • Github
  • Runbot
  • การแปล
บริการ
  • โฮสติ้ง odoo.sh เซิร์ฟเวอร์
  • การสนับสนุน
  • อัปเกรด
  • การพัฒนาที่กำหนดเอง
  • การศึกษา
  • ค้นหานักบัญชี
  • ค้นหาพาร์ทเนอร์
  • ร่วมเป็นพาร์ทเนอร์
เกี่ยวกับเรา
  • บริษัทของเรา
  • ทรัพย์สินในรูปของเครื่องหมายการค้า
  • ติดต่อเรา
  • งาน
  • ระบบการจัดงานอีเวนต์
  • พอดแคสต์
  • บล็อก
  • ลูกค้า
  • กฎหมาย • ความเป็นส่วนตัว
  • ความปลอดภัย
الْعَرَبيّة Català 简体中文 繁體中文 (台灣) Čeština Dansk Nederlands English Suomi Français Deutsch हिंदी Bahasa Indonesia Italiano 日本語 한국어 (KR) Lietuvių kalba Język polski Português (BR) română русский язык Slovenský jazyk slovenščina Español (América Latina) Español ภาษาไทย Türkçe українська Tiếng Việt

Odoo เป็นชุดแอปธุรกิจแบบเปิดที่ครอบคลุมทุกความต้องการของบริษัทของคุณ อาธิ CRM eCommerce ระบบบัญชี ระบบสินค้าคงคลัง ระบบการขายหน้าร้าน โปรเจกต์ และ อีกมากมาย

ความเหนือกว่าอันเป็นเอกลักษณ์ของ Odoo คือการใช้งานที่ง่ายดายและผสานการทำงานอย่างสมบูรณ์แบบในเวลาเดียวกัน

Website made with

Odoo Experience on YouTube

1. Use the live chat to ask your questions.
2. The operator answers within a few minutes.

Live support on Youtube
Watch now