[PATCH proxmox-backup v6 21/22] ui: expose counter reset schedule edit window

Christian Ebner
2026-03-19T09:41:31Z

Shows the counter reset schedule in the datastore options and allows
editing.

Signed-off-by: Christian Ebner <c.ebner@proxmox.com>
---
www/Makefile | 1 +
www/datastore/OptionView.js | 7 +++++++
www/window/CounterResetScheduleEdit.js | 27 ++++++++++++++++++++++++++
3 files changed, 35 insertions(+)
create mode 100644 www/window/CounterResetScheduleEdit.js

diff --git a/www/Makefile b/www/Makefile
index 5002bae90..8ac338f2d 100644
--- a/www/Makefile
+++ b/www/Makefile
@@ -77,6 +77,7 @@ JSSRC= \
window/ACLEdit.js \
window/BackupGroupChangeOwner.js \
window/CreateDirectory.js \
+ window/CounterResetScheduleEdit.js \
window/DataStoreEdit.js \
window/NamespaceEdit.js \
window/MaintenanceOptions.js \
diff --git a/www/datastore/OptionView.js b/www/datastore/OptionView.js
index f800c167f..a9253c6e9 100644
--- a/www/datastore/OptionView.js
+++ b/www/datastore/OptionView.js
@@ -343,5 +343,12 @@ Ext.define('PBS.Datastore.Options', {
xtype: 'pbsNotificationThresholdsEdit',
},
},
+ 'counter-reset-schedule': {
+ required: true,
+ header: gettext('Counter Reset Schedule'),
+ editor: {
+ xtype: 'pbsCounterResetScheduleEdit',
+ },
+ },
},
});
diff --git a/www/window/CounterResetScheduleEdit.js b/www/window/CounterResetScheduleEdit.js
new file mode 100644
index 000000000..6d0cd5d73
--- /dev/null
+++ b/www/window/CounterResetScheduleEdit.js
@@ -0,0 +1,27 @@
+Ext.define('PBS.window.CounterResetScheduleEdit', {
+ extend: 'Proxmox.window.Edit',
+ alias: 'widget.pbsCounterResetScheduleEdit',
+ mixins: ['Proxmox.Mixin.CBind'],
+
+ userid: undefined,
+ isAdd: false,
+
+ subject: gettext('Counter Reset Schedule'),
+
+ cbindData: function (initial) {
+ let me = this;
+
+ me.datastore = encodeURIComponent(me.datastore);
+ me.url = `/api2/extjs/config/datastore/${me.datastore}`;
+ me.method = 'PUT';
+ me.autoLoad = true;
+ return {};
+ },
+
+ items: {
+ xtype: 'pbsCalendarEvent',
+ name: 'counter-reset-schedule',
+ fieldLabel: gettext('Counter Reset Schedule'),
+ emptyText: gettext('none (disabled)'),
+ },
+});
--
2.47.3