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>
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>
'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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
and calculate it by getting the next event after 'now' since
we currently have no way to get the last run time for jobs only running
on different cluster nodes
Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
Ext.util.Sorter does not have an 'order' property, so 'order: DESC'
didn't have an effect. The default is 'ASC' and it is arguably the
preferred direction for all affected sorters anyways.
Signed-off-by: Fabian Ebner <f.ebner@proxmox.com>
we're thinking of maybe just auto-filling it or allowing to edit it,
in any way, the comment field can/should be used for longer, free
form info.
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
we can now show the id (since its not autogenerated anymore),
and we can always show/edit the schedule instead of the dow+starttime
also add an 'ID' field to the edit/create window and update the
backupinfo window as well
Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
Previously, only the storages for the local node would be shown, which
prevented configuring a job for remote nodes when the storage is not
available on the local node.
Signed-off-by: Fabian Ebner <f.ebner@proxmox.com>
makes it quite concise, but there's nothing really complex happening,
so should be still easy to grasp (especially with the comment added)
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
While it surely is nice to follow the layout of the job creation/edit
panel for sharing familiarity, it does not means that we need to show
the data 1:1, we can profit from the read-only fact and merge stuff a
bit, like the mail to/when field.
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
This was already possible via API (or manually editing vzdump.cron)
for a long time, but the settings were not visible in the UI at all.
Signed-off-by: Fabian Ebner <f.ebner@proxmox.com>
And also add the 'backup-info' endpoint to the index.
Suggested-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
Signed-off-by: Fabian Ebner <f.ebner@proxmox.com>
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>