aboutsummaryrefslogtreecommitdiffstats
path: root/util
diff options
context:
space:
mode:
Diffstat (limited to 'util')
-rw-r--r--util/dataforms.lua4
1 files changed, 3 insertions, 1 deletions
diff --git a/util/dataforms.lua b/util/dataforms.lua
index 6bd44bdc..4daebbcb 100644
--- a/util/dataforms.lua
+++ b/util/dataforms.lua
@@ -107,8 +107,10 @@ function form_t.form(layout, data, formtype)
value = datetime.datetime(value);
elseif field_type == "boolean" then
value = value ~= 0;
+ elseif field.datatype == "xs:double" or field.datatype == "xs:decimal" then
+ value = ("%f"):format(value);
else
- value = ("%g"):format(value);
+ value = ("%d"):format(value);
end
end
-- Add value, depending on type