public inbox for pve-devel@lists.proxmox.com
 help / color / mirror / Atom feed
From: Fabian Ebner <f.ebner@proxmox.com>
To: pve-devel@lists.proxmox.com
Subject: [pve-devel] [PATCH manager 3/3] fix #2745: backup GUI: allow users to specify remove=1
Date: Mon, 19 Oct 2020 14:33:14 +0200	[thread overview]
Message-ID: <20201019123314.8303-3-f.ebner@proxmox.com> (raw)
In-Reply-To: <20201019123314.8303-1-f.ebner@proxmox.com>

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@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





      parent reply	other threads:[~2020-10-19 12:33 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-10-19 12:33 [pve-devel] [PATCH guest-common 1/3] mention prune behavior for the vzdump remove parameter Fabian Ebner
2020-10-19 12:33 ` [pve-devel] [PATCH manager 2/3] partially fix #2745: use default for " Fabian Ebner
2020-10-19 12:33 ` Fabian Ebner [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20201019123314.8303-3-f.ebner@proxmox.com \
    --to=f.ebner@proxmox.com \
    --cc=pve-devel@lists.proxmox.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
Service provided by Proxmox Server Solutions GmbH | Privacy | Legal