Commit Graph

457 Commits

Author SHA1 Message Date
Lukas Wagner
b98ffc0d54 ui: backup: replication: replace non-clickable checkbox with icons
From a usability view, having a checkbox that is not clickable is pretty
misleading, especially if the visual style is exactly the same as in
other places in the UI where the checkbox is functional.

Signed-off-by: Lukas Wagner <l.wagner@proxmox.com>
2023-03-17 11:20:43 +01:00
Dominik Csapak
d232c409f6 ui: BackupEdit: refactor edit window into declarative style
simplifies some things, e.g. en/disabling the grid and pool selector
while refactoring, cleanup up some smaller things like nested if/else
paths, unnecessary splitting of the deprecated 'dow' parameter, etc.

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-03-11 18:47:34 +01:00
Dominik Csapak
e440f8a46a fix #4490: ui: add column filters in Backup Job edit window
by replacing the manual vm grid implementation and reusing the
VMSelector we already have. Since this is a full-fledged form field, we
can drop the complicated selection tracking / reselecting that we did
by saving into a hidden field.

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-03-11 18:47:34 +01:00
Dominik Csapak
13d465c146 ui: refactor refreshing the the resource store/tree
we'll need it elsewhere too, and it was rather hidden in the
updateTagSettings call.

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
2023-02-22 09:12:36 +01:00
Dominik Csapak
731436ee86 ui: refactor ui option related methods into UIOptions
a new singleton like Utils/Parser, intended for holding stuff for
ui options, such as the tag settings/overrides

no behavioural change intended

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
2023-02-22 09:12:36 +01:00
Lukas Wagner
93c425e109 ui: ldap: fix Parameter verification error
...when editing LDAP realm sync settings and only a single property is
empty and thus to be deleted (e.g. values.delete = "filter").

If `delete` is a simple string and not an array,
`PVE.Utils.delete_if_default` simply creates a comma-separated list,
(e.g. value.delete = "filter,sync-attributes").

When the properties from the other panel are evaluated and added to the
the `delete` property, comma-separated list format is not considered,
leading to a final value for `delete` that could look like this:
  value.delete = {
    "server2",
    "comment",
    "filter,sync-attributes"
  }

This commit fixes this by splitting `delete` in case it is a string.

Reported-by: Friedrich Weber <f.weber@proxmox.com>
Signed-off-by: Lukas Wagner <l.wagner@proxmox.com>
Tested-by: Friedrich Weber <f.weber@proxmox.com>
2023-02-15 10:12:51 +01:00
Thomas Lamprecht
2b7327234b ui: metrics: expose verify-certificate for influxdb as advanced setting
Ideally we'd offer fingerprint validation, but it's already nice to
allow admins configure the no-cert-verify through the UI, e.g., when
testing the metrics stack pre-deployment or for internally hosted
instances with a trusted DNS.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-01-28 12:39:40 +01:00
Thomas Lamprecht
f6717dfce9 ui: metrics: avoid repeated querys of the view
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-01-28 12:39:36 +01:00
Daniel Tschlatscher
6e3c144219 fix typo in user tag access text field
This text is only displayed when at least one tag is defined in the
User Tag Access editor.

Signed-off-by: Daniel Tschlatscher <d.tschlatscher@proxmox.com>
2023-01-25 12:58:54 +01:00
Fiona Ebner
b7b7b661f6 ui: cluster info: fix displaying error
The function to set the error mask expects the message as a string,
not the error object.

Signed-off-by: Fiona Ebner <f.ebner@proxmox.com>
2023-01-24 16:15:44 +01:00
Lukas Wagner
b52d2b12db ui: fix search for 'Guests without Backup' window
In JS, a `for (const a in <...>)` loop iterates over indices, not
over values. To iterate over values, `for (const a of <..>)` has
to be used. Furthermore, filtering by ID did not work properly, since
the property is called `vmid`, not `id`.

Signed-off-by: Lukas Wagner <l.wagner@proxmox.com>
2023-01-20 09:55:01 +01:00
Dominik Csapak
cc911f63aa ui: backup view: add scrolling overflow handler for the toolbar
As we got reports that some buttons get cut-off on resolutions close
to our minimal 720p one, especially if the "guest not in backup" jobs
hint is shown.

Link: https://forum.proxmox.com/threads/120714/
Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
 [ T: resolve merge conflict and reword commit message ]
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-01-19 18:07:26 +01:00
Thomas Lamprecht
38e79438f7 ui: backup info: code cleanups
And switch the title of the "not in any job" info window to title
case, just like the button that opens it.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-01-19 17:33:24 +01:00
Thomas Lamprecht
315feceaa8 ui: backup info: merge not-in-any-job warning into button to save space
We got reports in the forum about accessibility issues, as buttons
where cut-off due to the relatively long warning.

Use the old text as tooltip for the button and add the icon also
there.

Link: https://forum.proxmox.com/threads/120714/#post-526376
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-01-19 17:30:30 +01:00
Thomas Lamprecht
9a1678c5c5 ui: backup info: use collapsible field set to render retention config
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-01-19 16:41:52 +01:00
Thomas Lamprecht
a4240b80e8 ui: backup info: make initial height dependent of body view-height
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-01-19 16:41:21 +01:00
Thomas Lamprecht
64f3f34623 ui: backup info: move pool-to-backup to column 2 for balance
Its only shown sometimes and with this patch it's adjacent to the
selection mode, so quite fitting also from that POV.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-01-19 16:23:53 +01:00
Thomas Lamprecht
e040ee2827 ui: backup info: drop "Email" from "Notification" label
avoids extra vertical space usage due to a long label that's broken
up in multiple lines while not really loosing any relevant info.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-01-19 16:18:39 +01:00
Thomas Lamprecht
3d5b3eb6b6 ui: backup info: avoid clunky switch for simple mapping
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-01-19 16:16:49 +01:00
Dominik Csapak
4c1fe169b4 ui: reduce default size of Backup detail window
on our minimal display size (1280x720), using height 700 is too large
when considering that the browser + os also need some vertical space.

For good measure, use a maximum of 600 pixels. Since the window is
resizable anyway, users with more space should not have a problem here.

reported in the forum:
https://forum.proxmox.com/threads/web-forms-extend-beyond-web-page-window-in-some-cases.120714

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
2023-01-18 16:21:49 +01:00
Thomas Lamprecht
5a9848fac0 fix #1295: ui: allow one to configure new notification settings
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-01-03 16:51:31 +01:00
Dominik Csapak
5347251f8c ui: realm: sync: don't use realm defaults for remove-vanished
If we don't manually set it to 'none', it will use the realm default,
which might be unexpected. This way, the sync always does what the
user saw in the sync window.

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
2022-12-13 15:13:28 +01:00
Thomas Lamprecht
8fab87dc72 ui: dc options: support setting case sensitive
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2022-11-21 08:49:13 +01:00
Thomas Lamprecht
1d1a331949 ui: dc options: add Color-Overrides text to render, if any
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2022-11-21 08:48:53 +01:00
Thomas Lamprecht
9d7d39ef1c ui: datacenter options: add Cluster Resource Scheduling editor
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2022-11-18 17:26:38 +01:00
Dominik Csapak
56dee217bc ui: fix datacenter tags options inputs
* dont allow blank for tree shape
* allow completely removing registered tags and user-tag-access properties
* correctly check validity for the listfield
* use correct gettexts
* don't inject empty field in the listfield when setting an empty string

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
2022-11-18 12:56:18 +01:00
Thomas Lamprecht
13a0c8bf11 ui: eslint auto-fixes
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2022-11-17 18:21:48 +01:00
Dominik Csapak
1f359096b6 ui: tags: add preview to tag shape option
with a combogrid and the example text 'preview'

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
2022-11-17 18:21:48 +01:00
Dominik Csapak
432aec5641 ui: change style of ListField
and make it more like the 'traffic control' time grid in pbs

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
2022-11-17 18:21:48 +01:00
Dominik Csapak
8d8ba23da9 ui: implement tag ordering as configured in datacenter config
datacenter.cfg returns an 'ordering' option. parse that and
use it to order the tags when viewing. default is alphabetical.

With alphabetical ordering, drag & drop when editing is disabled and the
tags will be inserted at the right place. When saving, the sorted
order will be written into the config

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
2022-11-17 18:21:23 +01:00
Dominik Csapak
0a627d9468 ui: dc/OptionView: add editors for tag settings
namely for 'tag-tree-style' and 'tag-colors'.
display the tag overrides directly as they will appear as tags

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
2022-11-17 18:20:53 +01:00
Dominik Csapak
b7f4cb7cf9 ui: save ui options from /cluster/options instead of version
/cluster/options is now the go to place for getting these options
(until we have more options unrelated to the datacenter.cfg)

Also move the use of the console from VersionInfo to here, since
this will be the future place for ui related backend options.

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
2022-11-17 18:20:12 +01:00
Dominik Csapak
2389b2fa05 ui: backup job edit: fix form reset tracking
When the mode changes, we set the pool selector visible/hidden, but
we never disabled/enabled it. This tripped up the dirty state of the
form always showing the reset button as enabled.

Properly enabling and disabling the pool field fixes the dirty state
tracking.

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
2022-11-15 14:28:57 +01:00
Daniel Tschlatscher
98246fb7ea gui: fix firewall security group help button chapter link
The help button under Datacenter > Firewall > Security Group did not
have the proper help chapter link set.

First reported here:
https://forum.proxmox.com/threads/broken-help-link-in-proxmox-gui.117503/

Signed-off-by: Daniel Tschlatscher <d.tschlatscher@proxmox.com>
2022-11-04 10:32:44 +01:00
Aaron Lauterer
d9416caa1d ui: dc: subscription: fix subscription check
With the change to the rust backend for the subscription check, the
return value changed as well.

Signed-off-by: Aaron Lauterer <a.lauterer@proxmox.com>
2022-10-19 14:05:20 +02:00
Fiona Ebner
93880785c8 vzdump: handle new 'performance' property string
Also generalizes the way vzdump property strings are handled for jobs.
Something similar could be done in VZDump.pm, but there the maxfiles
and prune-backups settings are currently coupled, so a dedicated
parse_performance() is used instead. Can be changed once maxfiles is
dropped.

Signed-off-by: Fiona Ebner <f.ebner@proxmox.com>
2022-10-10 13:04:17 +02:00
Thomas Lamprecht
bad1742cef ui: datacenter: use "Name" label for respective part of full rp
as contrary to the property name this is actually only the rather
irrelevant part (auth wise) of the whole relying party, the ID is the
other part, and that one actually matters.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2022-07-26 12:00:45 +02:00
Thomas Lamprecht
727b64aec3 ui: datacenter: rework webauthn settings UX
Make origin optional, as it actually is, and its not covered by the
challenge anyway.

Also, not the thing we name rp, but the ID is important for the
validity of existing webauthn records, this error comes from the
confusing use of the same named thing in different ways by browsers,
us and the webauthn rust crate...

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2022-07-25 16:48:32 +02:00
Dominik Csapak
9cd2e6382c ui: dc/Backup: add 'repeat-missed' checkbox
so that the users can configure how to handle missed job runs
move the vmgrid inside the ipanel in 'columnB', so that the
advanced items show below the vmgrid (not above)

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
Reviewed-by: Fabian Ebner <f.ebner@proxmox.com>
2022-06-17 17:21:56 +02:00
Fabian Ebner
03875d7ac4 ui: manual backup: list possible template variables directly
rather than as a tooltip.

Suggested-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
Signed-off-by: Fabian Ebner <f.ebner@proxmox.com>
2022-05-12 17:17:56 +02:00
Dominik Csapak
2637f372fe ui: realm sync: let users set 'remove vanished options' independently
and label it correctly. The 'Properties' option was mislabeled,
it means 'remove vanished fields from synced users', not 'remove
fields from vanished users'.

So don't couple that with the 'Entries' option, and update the label
to convey the right meaning.

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
2022-05-02 15:28:27 +02:00
Dominik Csapak
a9faeb43ad ui: dc/SyncWindow: realign to sync options
put the checkboxes in a fieldset and reuse their labels

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
2022-04-29 14:23:30 +02:00
Fabian Ebner
34721757e7 close #438: ui: backup job: allow setting a notes-template for a job
Add a tooltip to the comment field, to better distinguish it from the
notes-template.

Signed-off-by: Fabian Ebner <f.ebner@proxmox.com>
Co-authored-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2022-04-28 14:16:04 +02:00
Thomas Lamprecht
47353b27df ui; datacenter options: add next-id editor
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2022-04-27 20:34:37 +02:00
Thomas Lamprecht
04f27b64d9 ui: realm sync: use fieldset for remove-vanished & ux/wording
Use fieldsets, which are just way nicer for grouping these things.

Disable the "remove properties" checkbox if we'd remove the whole
user anyway.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2022-04-26 14:26:11 +02:00
Dominik Csapak
3e43739f57 ui: realm sync: replace 'full' and 'purge' with 'remove-vanished'
in default sync options and the sync window. We do this by exposing
the individual flags as checkboxes. We get the mapped value from the
backend so we do not have to handle 'old' values here.

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
2022-04-26 13:35:03 +02:00
Thomas Lamprecht
56148f253e ui: utils: drop some useles _array helpers, just use Object.entries
if we need to enforce ordering it may help to reintroduce them
though.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2022-04-26 09:07:14 +02:00
Stefan Sterz
742de03d5a ui: move NotesView panel and NotesEdit window to widget kit
this removes the NotesView panel and NotesEdit and replaces them with
with the version from the widget kit. requires a bump of the widget
toolkit.

Signed-off-by: Stefan Sterz <s.sterz@proxmox.com>
2022-04-13 11:35:30 +02:00
Thomas Lamprecht
31de6834c5 ui: backup/run now: avoid passing "next-run" parameter to backend
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2022-01-18 05:48:44 +01:00
Thomas Lamprecht
5a85eaec27 ui: backuo job detail: drop being stateful, increase default height
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2022-01-13 16:55:15 +01:00