From 1d70e3812cc12855ea66637d12227b4ffe0b2ade Mon Sep 17 00:00:00 2001 From: Dominik Csapak Date: Fri, 5 Feb 2021 15:26:19 +0100 Subject: [PATCH] ui: tape/DriveConfig: add Catalog button Signed-off-by: Dominik Csapak --- www/tape/DriveConfig.js | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) diff --git a/www/tape/DriveConfig.js b/www/tape/DriveConfig.js index 8eb40da3..0d28eb87 100644 --- a/www/tape/DriveConfig.js +++ b/www/tape/DriveConfig.js @@ -57,6 +57,16 @@ Ext.define('PBS.TapeManagement.DrivePanel', { }); }, + catalog: function(view, rI, cI, button, el, record) { + let me = this; + let drive = record.data.name; + me.driveCommand(drive, 'catalog', function(response) { + Ext.create('Proxmox.window.TaskViewer', { + upid: response.result.data, + }).show(); + }, {}, 'POST'); + }, + readLabel: function(view, rI, cI, button, el, record) { let me = this; let drive = record.data.name; @@ -286,7 +296,7 @@ Ext.define('PBS.TapeManagement.DrivePanel', { }, { text: gettext('Actions'), - width: 120, + width: 140, xtype: 'actioncolumn', items: [ { @@ -301,6 +311,11 @@ Ext.define('PBS.TapeManagement.DrivePanel', { iconCls: 'fa fa-tag', handler: 'readLabel', }, + { + iconCls: 'fa fa-book', + handler: 'catalog', + tooltip: gettext('Catalog'), + }, { iconCls: 'fa fa-info-circle', handler: 'status',