mirror of
https://github.com/odoo/owl.git
synced 2025-10-06 19:59:41 +07:00
[FIX] qweb: conditional t-call with body
When a t-call has a condition and a body the t-if's and its flavors should be ignored when compiling the body of a t-call
This commit is contained in:
committed by
Géry Debongnie
parent
b96ea79f2b
commit
08022b49df
@@ -242,7 +242,9 @@ QWeb.addDirective({
|
||||
ctx.indent();
|
||||
protectID = ctx.startProtectScope();
|
||||
const nodeCopy = node.cloneNode(true) as Element;
|
||||
nodeCopy.removeAttribute("t-call");
|
||||
for (let attr of ["t-if", "t-else", "t-elif", "t-call"]) {
|
||||
nodeCopy.removeAttribute(attr);
|
||||
}
|
||||
const parentNode = ctx.parentNode;
|
||||
ctx.parentNode = "__0";
|
||||
// this local scope is intended to trap c__0
|
||||
|
||||
Reference in New Issue
Block a user