Bỏ qua để đến Nội dung
Menu
Câu hỏi này đã bị gắn cờ
1 Trả lời
19088 Lượt xem

Any body please explain me t-extend and t-jquery with a example in qweb reports

Ảnh đại diện
Huỷ bỏ
Câu trả lời hay nhất

t-extend is used to extend an existing template

You will see qweb templates in the base module like:

<t t-name="layout">
....
</t>

You can use <t t-extend="module_name.layout" > to extend these and insert new qweb elements.

<t t-jquery> is used to specify a postion.

For example,

<t t-name="layout">
<span class="some_class">Hello</span>
</t>

You could extend this by using:

<t t-jquery="span.some_class" t-operation="after">
</t>

t-jquery is usually used in conjuction with t-operation much like <xpath expr="" position="" /> 

Hope this helps.






Ảnh đại diện
Huỷ bỏ

If you browse through some modules, you should get the hang of it. Let me know if you need more help.

Bài viết liên quan Trả lời Lượt xem Hoạt động
1
thg 7 25
1937
1
thg 5 25
2027
1
thg 4 25
2441
1
thg 2 25
1727
0
thg 10 24
1477