mirror of
https://git.proxmox.com/git/proxmox-backup
synced 2025-04-28 18:50:04 +00:00

The `Add datastore` window labels the flag for creating a removable datastore as `Removable datastore`, while creating the datastore via the storage/disks interface will refer to it as `is removable`. Use the same `Removable datastore` as label for both locations. Signed-off-by: Christian Ebner <c.ebner@proxmox.com>
64 lines
1.3 KiB
JavaScript
64 lines
1.3 KiB
JavaScript
Ext.define('PBS.window.CreateDirectory', {
|
|
extend: 'Proxmox.window.Edit',
|
|
xtype: 'pbsCreateDirectory',
|
|
|
|
subject: Proxmox.Utils.directoryText,
|
|
showProgress: true,
|
|
isCreate: true,
|
|
url: '/nodes/localhost/disks/directory',
|
|
method: 'POST',
|
|
|
|
onlineHelp: 'storage-disk-management',
|
|
|
|
items: [
|
|
{
|
|
xtype: 'pmxDiskSelector',
|
|
name: 'disk',
|
|
valueField: 'name',
|
|
typeProperty: 'usage-type',
|
|
nodename: 'localhost',
|
|
diskType: 'unused',
|
|
fieldLabel: gettext('Disk'),
|
|
allowBlank: false,
|
|
},
|
|
{
|
|
xtype: 'proxmoxKVComboBox',
|
|
comboItems: [
|
|
['ext4', 'ext4'],
|
|
['xfs', 'xfs'],
|
|
],
|
|
fieldLabel: gettext('Filesystem'),
|
|
name: 'filesystem',
|
|
value: '',
|
|
allowBlank: false,
|
|
},
|
|
{
|
|
xtype: 'proxmoxtextfield',
|
|
name: 'name',
|
|
fieldLabel: gettext('Name'),
|
|
allowBlank: false,
|
|
},
|
|
{
|
|
xtype: 'proxmoxcheckbox',
|
|
name: 'add-datastore',
|
|
fieldLabel: gettext('Add as Datastore'),
|
|
value: '1',
|
|
listeners: {
|
|
change(field, newValue, _oldValue) {
|
|
let form = field.up('form');
|
|
let rmBox = form.down('[name=removable-datastore]');
|
|
|
|
rmBox.setDisabled(!newValue);
|
|
rmBox.setValue(false);
|
|
},
|
|
},
|
|
},
|
|
{
|
|
xtype: 'proxmoxcheckbox',
|
|
name: 'removable-datastore',
|
|
fieldLabel: gettext('Removable datastore'),
|
|
},
|
|
],
|
|
});
|
|
|