Add all buttons to default form view

issue9870
review333231002
This commit is contained in:
Cédric Krier committed 2020-12-05 11:43:59 +01:00
1 parent 6d4b00403f
commit 0aa6c7c80b
2 files changed
+6

No files matched your search

+1
View File
@@ -1,3 +1,4 @@
* Add all buttons to default form view
* Unify PYSON string format
* Forbid all white spaces except space in Char field
+5
View File
@@ -334,6 +334,11 @@ class ModelView(Model):
xml += "<newline/>"
else:
xml += '<field name="%s" colspan="4"/>' % (i,)
if cls._buttons:
xml += '<group id="buttons" col="-1" colspan="4">'
for button in cls._buttons:
xml += '<button name="%s"/>' % button
xml += '</group>'
xml += "</form>"
elif view_type == 'tree':
field = 'id'