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

i need your help.

im trying to edit the list that appears in a box when you hover the item in the gantt view.

i use t-esc but when i want to display for example the employee's name...

it works but i've the id too...

i just want the name...



here is an example :

< li>< t t-esc="employee_id"/ >< /li >

give this

432, employee name



i just want the employee's name and not the id before.

i hope someone can help me on this.

best regards

Max
อวตาร
ละทิ้ง
ผู้เขียน คำตอบที่ดีที่สุด

I found the solution myself.

for those with the same problem just put [1]

t-esc="partner_id[1]"

it will display just the name without the id number.

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

Hello, 

Try  t-esc="employee_id.name"  or  t-esc="employee_id.display_name"

You can use the same idea for any other field, such as:

- employee_id.phone, employee_id.job_title

- employee_id.parent_id (for his manager)

- and even employee_id.parent_id.phone (for his manager's phone)


If this answer solved your problem, please mark it as best answer


อวตาร
ละทิ้ง
Related Posts ตอบกลับ มุมมอง กิจกรรม
2
ส.ค. 24
2978
2
ก.พ. 24
1850
1
พ.ค. 21
8998
1
ต.ค. 20
2641
1
มี.ค. 20
3601