]> git.proxmox.com Git - proxmox-widget-toolkit.git/commitdiff
toolkit: fix #1307: don\'t use language dependent separator
authorThomas Lamprecht <t.lamprecht@proxmox.com>
Tue, 19 Dec 2017 07:16:12 +0000 (08:16 +0100)
committerDominik Csapak <d.csapak@proxmox.com>
Thu, 11 Jan 2018 13:45:48 +0000 (14:45 +0100)
by default, extjs submits the language dependent decimal separator,
e.g., ',' (comma) for german and '.' (dot) for english.

We always want the dot.

commit 5c660b6d1302a5fbb3dcf477cf8b5adc9f798530 from pve-manager

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
Toolkit.js

index bcfdf8e3cb4f312f13b0a5a219b7cdea34e02c6e..166da4d6ffeb88f56b73c175e1bfa2d3a4f97475 100644 (file)
@@ -138,6 +138,12 @@ Ext.apply(Ext.form.field.VTypes, {
     passwordText: gettext('Passwords do not match')
 });
 
+// we always want the number in x.y format and never in, e.g., x,y
+Ext.define('PVE.form.field.Number', {
+    override: 'Ext.form.field.Number',
+    submitLocaleSeparator: false
+});
+
 // ExtJs 5-6 has an issue with caching
 // see https://www.sencha.com/forum/showthread.php?308989
 Ext.define('Proxmox.UnderlayPool', {