-
- Downloads
[ADD] QWeb: xml namespaces support in dynamic template
This is very similar and almost copy pasted from the implementation in static template, as the main method `compile_node` will either call `_compile_static_node` (which we patched in the static implementation) or `_compile_directives` which will call `_compile_tag` in the cases where xmlns matter (at least that's my understanding for today). So we patch `_compile_tag` the same way than `_compile_static_node`. It would be nicer if the method wasn't completely different and in two parts, but hey. This method is not always called on leaves, so setting options['nsmap'] to a copy before processing the content of the node is necessary (a node with a nsmap and a t-attf- having a child with an nsmap: the child has to be aware of the nsmap of its parent). Note that we set the xmlns attribtue before calling `_compile_all_attribute`, which will probably break xmlns set by t-* tag. However, we don't plan to support that the moment.
Loading
Please register or sign in to comment