Skip to Content
เมนู
คุณต้องลงทะเบียนเพื่อโต้ตอบกับคอมมูนิตี้
คำถามนี้ถูกตั้งค่าสถานะ
5 ตอบกลับ
8222 มุมมอง

Hi Dear,

I add an new char field to product.product as a "product_url" widget="url"

I need to add this field to qweb report for sale order where the cusomer could use this soft copy from sale order to visit product data sheet for more info.

I used the the following attribute:

<a href="line.product_id.product_url">data sheet link</a>, after print sale order pdf and click on data sheet link the attribute act as follow

http://localhost:8069/line.product_id.product_url not went to product data sheet link

อวตาร
ละทิ้ง
คำตอบที่ดีที่สุด
Try <a t-attf-href="line.url_field">URL</a> Hope it will works.
อวตาร
ละทิ้ง
คำตอบที่ดีที่สุด

<a t-attf-href =" #{line.product_id.product_url }" >data sheet link </a>

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

I'm facing a same issue and my hyperlinks are not working on the qweb report.

Let me know if anyone know what might be the issue.

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

Replacing "href" to "t-attr-href" in you code. like:

<a t-attr-href="line.product_id.product_url">data sheet link</a>

อวตาร
ละทิ้ง
ผู้เขียน คำตอบที่ดีที่สุด
<a t-att-href="line.field">text to display</a>
อวตาร
ละทิ้ง
Related Posts ตอบกลับ มุมมอง กิจกรรม
1
เม.ย. 25
10916
Download ir_attachments via Odoo Website แก้ไขแล้ว
2
ก.ค. 19
16170
3
ธ.ค. 19
5252
1
ก.ค. 25
1882
System redirect to a wrong url แก้ไขแล้ว
1
พ.ค. 25
858