Commit Graph

499 Commits

Author SHA1 Message Date
Thomas Lamprecht
81e102ebc2 ui: disable new notification UI for now, will be reworked
Lukas is currently reworking this so that we have a single panel,
where the filters are match-entries that can also provide the
functionality of the hard-coded filters in the other panel, reducing
complexity and adding flexibility.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-10-29 19:47:42 +01:00
Thomas Lamprecht
fea56c69dd ui: datacenter config: adapt to new default MAC prefix
The official Proxmox OUI, assigned by the IEEE, is now used as
default.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-10-29 18:02:21 +01:00
Thomas Lamprecht
5265a2d1a9 ui: clarify that compression selector is for backup only
other targets/sources might have a different list of available
compressions.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-10-11 15:59:45 +02:00
Lukas Wagner
84846fdc10 ui: notification: remove unneeded gettext calls
'mail-to-root' is the name of the default notification target and
should thus not be translated.

Signed-off-by: Lukas Wagner <l.wagner@proxmox.com>
2023-09-18 12:06:52 +02:00
Thomas Lamprecht
3dff70eb7e ui: notifications event: fix using gettext
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-09-14 08:15:02 +02:00
Lukas Wagner
c54ff6e901 ui: ldap: ad: replace occurences of SSL with TLS
Although 'SSL' is used colloquially, the proper term is 'TLS'.

Signed-off-by: Lukas Wagner <l.wagner@proxmox.com>
2023-09-04 18:07:27 +02:00
Lukas Wagner
2b9b6bc401 ui: ldap: ad: fix typo for verify certificate combobox
Signed-off-by: Lukas Wagner <l.wagner@proxmox.com>
2023-09-04 18:07:27 +02:00
Lukas Wagner
09a2f33458 ui: ldap: ad: support 'mode' paramter, replacing 'secure'
The backend has supported the 'mode' parameter for quite a while,
however it has not yet been exposed in the GUI, contrary to PMG
and PBS.

The benefit of 'mode' is that it supports LDAP, LDAPS and LDAP via
STARTTLS, compared to just LDAP/LDAPS for the 'secure' parameter.

The modified AuthEdit{LDAP,AD} panel will now automatically migrate
to the new paramter by hooking into onGetValues/onSetValues.

Signed-off-by: Lukas Wagner <l.wagner@proxmox.com>
2023-09-04 18:07:27 +02:00
Lukas Wagner
bacb4173fb ui: replication: backup: use renderEnabledIcon to render the enabled column
The new helper is available since proxmox-widget-toolkit version 3.6.1
which we can be sure to be available since a while in praxis, but
definitively by d/control constraints, since 51f54177 ("bump
proxmox-widget-toolkit dependency to 4.0.7")

Signed-off-by: Lukas Wagner <l.wagner@proxmox.com>
 [TL: add context since when this function is available ]
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-09-01 09:44:28 +02:00
Christian Ebner
347f88fecd website: update external links to www.proxmox.com
During the redesign of www.proxmox.com the menu structure and therefore
some url changed. Update the external link in order to avoid an
unneccessary redirect

Signed-off-by: Christian Ebner <c.ebner@proxmox.com>
2023-08-23 10:09:25 +02:00
Lukas Wagner
c81bca2d28 ui: dc: remove notify key from datacenter option view
Settings for notifications have been moved to their own view.

Signed-off-by: Lukas Wagner <l.wagner@proxmox.com>
2023-08-16 11:11:22 +02:00
Lukas Wagner
e4eb04d653 ui: add notification target configuration panel
Embed the new notification target configuration panel, implemented in
proxmox-widget-toolkit.

Signed-off-by: Lukas Wagner <l.wagner@proxmox.com>
2023-08-16 11:11:18 +02:00
Lukas Wagner
80c49bb56d ui: allow to configure notification event -> target mapping
This commit adds a new view that allows configuring notification
targets for all existing notification events (replication, updates,
fencing).

Signed-off-by: Lukas Wagner <l.wagner@proxmox.com>
2023-08-16 11:11:16 +02:00
Lukas Wagner
3be4491221 ui: backup: adapt backup job details to new notification params
Adapt the backup job detail view so that it shows notification
targets.

Signed-off-by: Lukas Wagner <l.wagner@proxmox.com>
2023-08-16 11:11:13 +02:00
Lukas Wagner
2c4780cc18 ui: backup: allow to select notification target for jobs
This commit adds a possibility to choose between different options
for notifications for backup jobs:
    - Notify via email, in the same manner as before
    - Notify via an endpoint/group

If 'notify via mail' is selected, a text field where an email address
can be entered is displayed:

    Notify:         | Always notify  v |
    Notify via:     | E-Mail         v |
    Send Mail to:   | foo@example.com  |
    Compression:    | .....          v |

If the other option is selected selected, a combo picker for selecting
a channel is displayed:

    Notify:         | Always notify  v |
    Notify via:     | Endpoint/Group v |
    Target:         | endpoint-foo   v |
    Compression:    | .....          v |

The code has also been adapted to use the newly introduced
'notification-policy' parameter, which replaces the 'mailnotification'
paramter for backup jobs. Some logic which automatically migrates from
'mailnotification' has been added.

Signed-off-by: Lukas Wagner <l.wagner@proxmox.com>
2023-08-16 11:11:12 +02:00
Christoph Heiss
b9d23c8787 ui: ldap: add 'Check connection' checkbox as advanced option
The checkbox is enabled by default, setting the new `check-connection`
parameter. See also [0] for the rationale.

[0] https://lists.proxmox.com/pipermail/pve-devel/2023-July/058559.html

Signed-off-by: Christoph Heiss <c.heiss@proxmox.com>
2023-08-11 13:38:19 +02:00
Friedrich Weber
98cbec545f ui: add some missing htmlEncodes
Signed-off-by: Friedrich Weber <f.weber@proxmox.com>
2023-07-25 16:59:09 +02:00
Thomas Lamprecht
c34c541820 ui: active directory realm: expose case-sensitive option
The case-sensitive option is not really something that should be CLI
only and is quite common for Microsoft AD setups, so add it to the UI
too as requested in the Forum [0], improving discoverability.

[0]: https://forum.proxmox.com/threads/74547/#post-575854

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-07-25 10:12:04 +02:00
Thomas Lamprecht
5eb250e2f8 ui: use common gettext for IOMMU-Group
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-06-21 18:02:53 +02:00
Dominik Csapak
0eb03eaa51 ui: resource mappings: remove border and add resize handle
aka a 'splitter'. that way the user can determine how much of each panel
he wants to see himself

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
2023-06-19 13:05:17 +02:00
Dominik Csapak
70eb18e8f0 ui: allow configuring pci and usb mapping
uses the new ResourceMapTree to add the CRUD interfaces for the
mappings.

We add both of them into a single panel, since the datacenter menu
already has many entries, and without a proper summary for the group, we
cannot really put them in a category

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
2023-06-16 16:25:42 +02:00
Thomas Lamprecht
1e7c70f5c2 ui: realm sync job: code cleanup run-now handlers
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-06-14 17:41:49 +02:00
Thomas Lamprecht
fc3fe9af77 ui: realm sync job: clarify the function of the two enable checkboxes
Most of the time this isn't an issue for job edits, but here we have
two "enable" checkboxes that control enabling newly synced users and
enabling the job itself, try to be absolutely clear on both to avoid
potential confusion.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-06-14 17:37:47 +02:00
Thomas Lamprecht
fc8f37ee9d ui: realm: clarify that the sync jobs really are for the realm
it's somewhat redundant as onbe is already at the realm view, but for
panel titles it slightly helps if one doesn't have to string together
such "clues" oneself, i.e., it's easier to see where one is - e.g.,
if switching from some other task back to the web UI again, and we
have enough space here, so we ain't winning anything if keeping it
short.

Also add an emptyText to the grid, mostly as view's without anything
always look a bit off (like an error happened on load and one forgot
to mask)

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-06-14 17:36:36 +02:00
Dominik Csapak
ed65c1ca64 ui: realm sync: add 'run now' button
by simply passing the sync job config to the 'sync' api endpoint, like
we do for vzdump jobs

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
2023-06-14 17:23:22 +02:00
Dominik Csapak
4c8fcdd7af ui: realm: move sync job panel into realm panel
and make it collapsible, so that users can hide it if they're not
interested in it

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
2023-06-14 17:23:22 +02:00
Dominik Csapak
059abb7a30 ui: realm sync: change enabled column rendering
to make it consistent with the repositories ui, since having a checkbox
that is not clickable is confusing

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
2023-06-14 17:23:22 +02:00
Dominik Csapak
99e276c3d9 ui: realm sync edit: improve ux when there is no ldap/ad realm
by adding an empty text to the dropdown, and disabling the other
possibly invalid fields, so that it's clear why the panel is invalid

as soon as there is an ldap/ad realm, it gets autoselected anyway and
the fields get re-enabled.

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
2023-06-14 17:23:22 +02:00
Thomas Lamprecht
7a1373829a ui: user list: fine-tune width-flex of group and comment column
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-06-14 16:17:39 +02:00
Dominik Csapak
7679ff9e60 fix #4739: ui: user list: add column for group memberships
To get a fast overview in which groups each user is add a column that
shows all groups they are a member of.

To get that info we need to pass the 'full=1' parameter to the API
endpoint, which then adds tokens and groups for each user to the result.

This is basically only increasing transmission size a bit, as the
backend doesn't needs to do any extra parsing for this information.

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
 [T: Reword commit message ]
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-06-14 15:36:55 +02:00
Thomas Lamprecht
5f936d95fc ui: sdn: consistent usage of VNet & VLAN without gettext
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-06-14 14:10:56 +02:00
Thomas Lamprecht
7b54999a47 ui: fixup lost closing parenthesis
...

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-06-09 09:55:45 +02:00
Thomas Lamprecht
22fcd0069a ui: user view: fix calling order of gettext
One must not call gettext on the already formatted string, as we
cannot translate it for any possible value, rather the format string
it self needs to be gettext'd, then the translator can position the
variable template placeholders however it's correct for their
language without having to care about any value this could be called
with.

Fixes: d057929f ("ui: user view: fix calling order of gettext")
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-06-09 09:53:03 +02:00
Wolfgang Bumiller
5970607408 ui: user view: add 'Unlock TFA' button
Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
2023-06-07 18:08:01 +02:00
Wolfgang Bumiller
2387c1946a ui: user view: show tfa lock status
Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
2023-06-07 18:08:01 +02:00
Dominik Csapak
1056e10c4b ui: firewall: refactor privilege checks and prevent double click
factor out the relevant privilege checks in a variable and reuse that,
also add the check in the run_editor (or wrap it with a check) so that
the edit windows don't open with a double click without those privileges

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
2023-06-07 13:22:03 +02:00
Alexandre Derumier
2e37e77902 ui: firewall panel/grids : add privilege checks on buttons
Use enableFn to enable/disable the toolbar buttons according to the
existing privileges.

Signed-off-by: Alexandre Derumier <aderumier@odiso.com>
[ D: adapted commit subject and added commit message ]
Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
2023-06-07 13:21:48 +02:00
Dominik Csapak
f44ce5955e ui: add Realm Sync panel
a typical CRUD panel for adding/editing/removing realm sync jobs

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-06-07 11:38:34 +02:00
Thomas Lamprecht
13831d8d3d ui: dc summary: code style fix
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-06-05 19:04:12 +02:00
Dominik Csapak
25f7446c90 fix #4627: ui: backup edit: don't deselect all guests on load
'selectPoolMembers' will be called when the poolid field changes.
(That can even happen when the mode is not even 'pool') Due to how
the fields are set, there is a race condition that this will be
called after the remaining fields were set up, including the VM list
that might have entries selected.

Since the first thing we do here is to deselect all, this wiped the
virtual guest selection sometimes.

To fix it, check if we're actually in the correct mode before doing
anything.

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
2023-04-12 13:27:57 +02:00
Thomas Lamprecht
239214560b ui: datacenter options: add HA 'Rebalance on Start' to CRS options
and make the window wider to avoid many lines for the boxLabel
explanation

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-03-20 20:09:40 +01:00
Thomas Lamprecht
de422b3e7e ui: make renderEnabledIcon inline for now
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-03-17 11:37:01 +01:00
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