Commit Graph

25 Commits

Author SHA1 Message Date
Thomas Lamprecht
08e38f032d ui: printPropertyString: skip empty string values
This cannot work anyway, and it simplifies some editors for
format-string backed properties, like the upcoming u2f settings
integration.

If such a value was passed to the backend one would get:
> invalid format - missing key in comma-separated list property

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2019-11-26 17:00:29 +01:00
Thomas Lamprecht
4a7248d4ea ui: make parsePropertyString less picky
simply return a empty object for cases we would get an exception
anyway, this is not wrong and allows easier usage for cases where
it's not sure if the value is set or not.

We could still do a Ext.isDebugEnabled() check and then throw up, but
this really should not matter much and I do not like if my debug mode
breaks and the non-debug not..

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2019-10-04 16:20:24 +02:00
Thomas Lamprecht
6de2baee56 ui/Parser: printPropertyString: sort non-defaultKey parts for stability
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2019-07-10 14:57:40 +02:00
Christian Ebner
150ad74a2c fix #2190: Base64 encode SMBIOS value strings in order to allow more characters
On some occasions e.g. license checking, the manufacturer string in the
SMBIOS settings edit has to allow characters such as whitespaces.
https://forum.proxmox.com/threads/proxmox-and-windows-rok-license-for-dell.53236/
In principle SMBIOS allows to pass any zero terminated string to the
corresponding fields in the structure type 1 (System Information).

By base64 encoding the values clashing of the config is avoided.

Relies on the corresponding patch to qemu-server to pass parameter verification
and correct parsing.

Signed-off-by: Christian Ebner <c.ebner@proxmox.com>
2019-06-11 17:42:33 +02:00
Thomas Lamprecht
f92943e2f8 make jslint happier
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2019-04-16 07:46:59 +00:00
Wolfgang Bumiller
1cdb49c199 www: parser: add parseTfaType helper
The tfa keys can now contain the type as additional
information, so let's parse it out.

Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
2019-04-16 07:02:05 +00:00
Dominik Csapak
805a7cb8b2 ui: parser use parseBoolean for firewall
so we detect on/ff,true/false,1/0

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
2019-04-04 16:59:04 +02:00
Thomas Lamprecht
95e77b22cc ui: ct: fix displaying nic firewall if explicitly 0
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2019-04-04 16:11:28 +02:00
Dominik Csapak
a108c35aaa gui: allow whitespace in mp paths
we do all necessary checks in the backend, and there we allow
whitespace in mp paths, so there is no need to restrict it in
the gui to non-whitespace characters

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
2018-08-22 11:15:53 +02:00
Thomas Lamprecht
8007aaaf87 ui/Parser: printPropertyString: simplify and always put defaultKey values first
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2018-08-02 16:20:12 +02:00
Thomas Lamprecht
9bbdcdff03 ui/Parser: parsePropertyString: log errors to console
allows to catch bugs faster as we get a call trace and may see this
error even when our caller doesn't handle an undefined return value
from this method.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2018-08-02 16:20:12 +02:00
Stoiko Ivanov
3d6189d304 ui/Parser: add generic functions property_strings
Signed-off-by: Stoiko Ivanov <s.ivanov@proxmox.com>
2018-08-02 16:01:12 +02:00
Dominik Csapak
488be4c2c0 add node/ACME.js
this provides the grid for editing domains for letsencrypt,
order/renew the certificates, and the window for creating an
ACME account

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
2018-05-04 16:11:00 +02:00
Dominik Csapak
01e02121c7 add qemu IPConfigEdit for CloudInit
resembles the lxc IPConfigEdit, but is slightly different

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
2018-03-16 10:05:57 +01:00
Wolfgang Bumiller
b1339314b6 lxc: wizard: ssh key 2016-08-19 13:54:38 +02:00
Dominik Csapak
22f2f9d6c0 jslint: remove trailing commas
before ECMA5 trailing commas in arrays and objects
are forbidden

in jslint this is an error and cannot be deactivated

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
2016-04-29 17:06:34 +02:00
Dominik Csapak
ec0bd652db jslint: fix type confusion and property access
fix various type confusion, for example:
items: {} and items: []
style: string and style: {}

also fix object['property'] access with
object.property

also fix /=/ with either '=' or /\=/ where appropriate
(/=/ can be confused with /= according to jslint)

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
2016-04-29 17:06:23 +02:00
Dominik Csapak
84de645d34 jslint: fix curly braces for if
in one change, there is also a change from object['property']
to object.property which jslint complains about

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
2016-04-29 17:05:44 +02:00
Dietmar Maurer
6efbc4cb9d lxc rate limit: do not write value 0 (simply omit value) 2016-04-22 10:13:31 +02:00
Dietmar Maurer
519ca7fafe LXC GUI: add network rate limit 2016-04-22 09:14:09 +02:00
Wolfgang Bumiller
63e62a6f89 whitespace cleanup 2016-04-11 11:56:40 +02:00
Wolfgang Bumiller
a2ed069746 qemu: parse vlan trunks
Fixes an error when trying to edit a network with assigned
trunks.
2016-04-11 11:56:32 +02:00
Wolfgang Bumiller
283b450ec5 parser: fix case sensitivity when classifying mountpoints 2016-03-18 16:27:03 +01:00
Emmanuel Kasper
4c1c0d5d2a copy missing methods from ExtJS 4 Parser.js 2016-03-09 18:02:28 +01:00
Dietmar Maurer
bac5bd135c rename manager5 to manager6 2016-01-22 11:24:10 +01:00