[pve-devel] [PATCH manager 3/3] fix #2745: backup GUI: allow users to specify remove=1
Fabian Ebner
f.ebner at proxmox.com
Mon Oct 19 14:33:14 CEST 2020
A user with Datastore.AllocateSpace, VM.Audit, VM.Backup
privileges can already remove backups from the GUI manually,
so it shouldn't be a problem if they can set the remove flag
when starting a manual vzdump job in the GUI.
Signed-off-by: Fabian Ebner <f.ebner at proxmox.com>
---
www/manager6/window/Backup.js | 17 ++++++++++++++---
1 file changed, 14 insertions(+), 3 deletions(-)
diff --git a/www/manager6/window/Backup.js b/www/manager6/window/Backup.js
index 55f52676..8649c738 100644
--- a/www/manager6/window/Backup.js
+++ b/www/manager6/window/Backup.js
@@ -67,8 +67,19 @@ Ext.define('PVE.window.Backup', {
fieldLabel: gettext('Send email to'),
name: 'mailto',
emptyText: Proxmox.Utils.noneText
- }
- ]
+ },
+ {
+ xtype: 'proxmoxcheckbox',
+ name: 'remove',
+ checked: false,
+ uncheckedValue: 0,
+ fieldLabel: gettext('Remove'),
+ autoEl: {
+ tag: 'div',
+ 'data-qtip': gettext('Remove/prune older backups afterwards'),
+ },
+ },
+ ],
});
var form = me.formPanel.getForm();
@@ -82,7 +93,7 @@ Ext.define('PVE.window.Backup', {
storage: storage,
vmid: me.vmid,
mode: values.mode,
- remove: 0
+ remove: values.remove,
};
if ( values.mailto ) {
--
2.20.1
More information about the pve-devel
mailing list