X-Git-Url: https://git.proxmox.com/?a=blobdiff_plain;f=www%2Fmanager6%2Fwindow%2FBackup.js;h=4418a9c7e51fc41ee1b05f79d0913c3f34dc4897;hb=c202b169f5b0294bb22d05a5385182098e18b3fd;hp=8d8c9ff019d72f37220fa30d4d61383cd371ada8;hpb=66b2086269b383e962ebbb6b90a39a368172f60f;p=pve-manager.git diff --git a/www/manager6/window/Backup.js b/www/manager6/window/Backup.js index 8d8c9ff0..4418a9c7 100644 --- a/www/manager6/window/Backup.js +++ b/www/manager6/window/Backup.js @@ -36,6 +36,23 @@ Ext.define('PVE.window.Backup', { emptyText: Proxmox.Utils.noneText, }); + let notificationModeSelector = Ext.create({ + xtype: 'proxmoxKVComboBox', + comboItems: [ + ['auto', gettext('Auto')], + ['legacy-sendmail', gettext('Email (legacy)')], + ['notification-system', gettext('Notification system')], + ], + fieldLabel: gettext('Notification mode'), + name: 'notification-mode', + value: 'auto', + listeners: { + change: function(field, value) { + mailtoField.setDisabled(value === 'notification-system'); + }, + }, + }); + const keepNames = [ ['keep-last', gettext('Keep Last')], ['keep-hourly', gettext('Keep Hourly')], @@ -110,6 +127,9 @@ Ext.define('PVE.window.Backup', { if (!initialDefaults && data.mailto !== undefined) { mailtoField.setValue(data.mailto); } + if (!initialDefaults && data['notification-mode'] !== undefined) { + notificationModeSelector.setValue(data['notification-mode']); + } if (!initialDefaults && data.mode !== undefined) { modeSelector.setValue(data.mode); } @@ -176,6 +196,7 @@ Ext.define('PVE.window.Backup', { ], column2: [ compressionSelector, + notificationModeSelector, mailtoField, removeCheckbox, ], @@ -256,6 +277,10 @@ Ext.define('PVE.window.Backup', { params.mailto = values.mailto; } + if (values['notification-mode']) { + params['notification-mode'] = values['notification-mode']; + } + if (values.compress) { params.compress = values.compress; }