ui: tape/PoolEdit: add selector for encryption keys
Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
This commit is contained in:
parent
2e4e698633
commit
5f1f7ef564
@ -15,6 +15,7 @@ TAPE_UI_FILES= \
|
||||
tape/form/PoolSelector.js \
|
||||
tape/form/RetentionSelector.js \
|
||||
tape/form/TapeDevicePathSelector.js \
|
||||
tape/form/KeySelector.js \
|
||||
tape/window/ChangerEdit.js \
|
||||
tape/window/DriveEdit.js \
|
||||
tape/window/EncryptionEdit.js \
|
||||
|
38
www/tape/form/KeySelector.js
Normal file
38
www/tape/form/KeySelector.js
Normal file
@ -0,0 +1,38 @@
|
||||
Ext.define('PBS.form.TapeKeySelector', {
|
||||
extend: 'Proxmox.form.ComboGrid',
|
||||
alias: 'widget.pbsTapeKeySelector',
|
||||
|
||||
allowBlank: false,
|
||||
displayField: 'hint',
|
||||
valueField: 'fingerprint',
|
||||
value: null,
|
||||
multiSelect: false,
|
||||
|
||||
|
||||
store: {
|
||||
proxy: {
|
||||
type: 'proxmox',
|
||||
url: '/api2/json/config/tape-encryption-keys',
|
||||
},
|
||||
autoLoad: true,
|
||||
sorter: 'hint',
|
||||
},
|
||||
|
||||
listConfig: {
|
||||
columns: [
|
||||
{
|
||||
text: gettext('Hint'),
|
||||
dataIndex: 'hint',
|
||||
sortable: true,
|
||||
flex: 1,
|
||||
renderer: Ext.String.htmlEncode,
|
||||
},
|
||||
{
|
||||
text: gettext('Fingerprint'),
|
||||
sortable: true,
|
||||
dataIndex: 'fingerprint',
|
||||
flex: 5,
|
||||
},
|
||||
],
|
||||
},
|
||||
});
|
@ -52,6 +52,17 @@ Ext.define('PBS.TapeManagement.PoolEditWindow', {
|
||||
deleteEmpty: '{!isCreate}',
|
||||
},
|
||||
},
|
||||
{
|
||||
fieldLabel: gettext('Encryption Key'),
|
||||
xtype: 'pbsTapeKeySelector',
|
||||
name: 'encrypt',
|
||||
allowBlank: true,
|
||||
skipEmptyText: true,
|
||||
autoSelect: false,
|
||||
cbind: {
|
||||
deleteEmpty: '{!isCreate}',
|
||||
},
|
||||
},
|
||||
],
|
||||
});
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user