It is possible to get the current record id using xml?
Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:
- CRM
- e-Commerce
- Kế toán
- Tồn kho
- PoS
- Dự án
- MRP
Câu hỏi này đã bị gắn cờ
Hi Harsh,
Thanks for your reply.
i have one doubt. What you mean by XML-ID
https://github.com/odoo/odoo/blob/16.0/addons/account/data/account_data.xml
<record id="account_tag_operating" model="account.account.tag">
<field name="name">Operating Activities</field>
<field name="applicability">accounts</field>
</record>
Lets say account.account.tag model if you see in above link "Operating Activities" this record created.
Let's say if you want to directly access this recordset without read or browse or search method use below line to get direct recordset.
self.env.ref("account.account_tag_operating")
account :- module name
account_tag_operating :- xml id
Thanks,
Bạn có hứng thú với cuộc thảo luận không? Đừng chỉ đọc, hãy tham gia nhé!
Tạo tài khoản ngay hôm nay để tận hưởng các tính năng độc đáo và tham gia cộng đồng tuyệt vời của chúng tôi!
Đăng ký