[IMP]Hy Odoo : allow XML data to have attributes, add XML node function

This commit is contained in:
Fabien BOURGEOIS 2020-04-27 11:29:07 +02:00
parent 01a73a2ce2
commit 18b963d2cd
1 changed files with 5 additions and 1 deletions

View File

@ -40,7 +40,11 @@
; XML helpers functions and macros
(defn odoo [&rest args] (xmlroot (xmln "odoo" {} #*args)))
(defn data [&rest args] (xmln "data" {} #*args))
(defn data [&rest args]
(if (= (len args) 1)
(xmln "data" {} #*args)
(xmln "data" #*args)))
(defn function [&rest args] (xmln "function" #*args))
(defn record [&rest args] (xmln "record" #*args))
(defn form [&rest args] (xmln "form" #*args))
(defn tree [&rest args] (xmln "tree" #*args))