hideAdd: true,
backups: false,
},
+ esxi: {
+ name: 'ESXi',
+ ipanel: 'ESXIInputPanel',
+ faIcon: 'cloud-download',
+ backups: false,
+ },
},
sdnvnetSchema: {
ipanel: 'BgpInputPanel',
faIcon: 'crosshairs',
},
+ isis: {
+ name: 'isis',
+ ipanel: 'IsisInputPanel',
+ faIcon: 'crosshairs',
+ },
},
sdnipamSchema: {
result = "CH " +
Ext.String.leftPad(data.channel, 2, '0') +
" ID " + data.id + " LUN " + data.lun;
+ } else if (data.content === 'import') {
+ result = data.volid.replace(/^.*?:/, '');
} else {
result = data.volid.replace(/^.*?:(.*?\/)?/, '');
}
// templates
objType = 'template';
status = type;
+ } else if (type === 'storage' && record.content.indexOf('import') !== -1) {
+ return 'fa fa-cloud-download';
} else {
// everything else
status = record.status + ' ha-' + record.hastate;
css: 'display:none;visibility:hidden;height:0px;',
});
- // Note: we need to tell Android and Chrome the correct file name extension
+ // Note: we need to tell Android, AppleWebKit and Chrome
+ // the correct file name extension
// but we do not set 'download' tag for other environments, because
// It can have strange side effects (additional user prompt on firefox)
- if (navigator.userAgent.match(/Android|Chrome/i)) {
+ if (navigator.userAgent.match(/Android|AppleWebKit|Chrome/i)) {
link.download = name;
}
}
},
- mp_counts: {
+ lxc_mp_counts: {
mp: 256,
unused: 256,
},
- forEachMP: function(func, includeUnused) {
- for (let i = 0; i < PVE.Utils.mp_counts.mp; i++) {
- let cont = func('mp', i);
+ forEachLxcMP: function(func, includeUnused) {
+ for (let i = 0; i < PVE.Utils.lxc_mp_counts.mp; i++) {
+ let cont = func('mp', i, `mp${i}`);
if (!cont && cont !== undefined) {
return;
}
return;
}
- for (let i = 0; i < PVE.Utils.mp_counts.unused; i++) {
- let cont = func('unused', i);
+ for (let i = 0; i < PVE.Utils.lxc_mp_counts.unused; i++) {
+ let cont = func('unused', i, `unused${i}`);
+ if (!cont && cont !== undefined) {
+ return;
+ }
+ }
+ },
+
+ lxc_dev_count: 256,
+
+ forEachLxcDev: function(func) {
+ for (let i = 0; i < PVE.Utils.lxc_dev_count; i++) {
+ let cont = func(i, `dev${i}`);
if (!cont && cont !== undefined) {
return;
}
return undefined;
},
- nextFreeMP: function(type, config) {
- for (let i = 0; i < PVE.Utils.mp_counts[type]; i++) {
+ nextFreeLxcMP: function(type, config) {
+ for (let i = 0; i < PVE.Utils.lxc_mp_counts[type]; i++) {
let confid = `${type}${i}`;
if (!Ext.isDefined(config[confid])) {
return {
'ok': 2,
'__default__': 3,
},
+
+ isStandaloneNode: function() {
+ return PVE.data.ResourceStore.getNodes().length < 2;
+ },
+
+ // main use case of this helper is the login window
+ getUiLanguage: function() {
+ let languageCookie = Ext.util.Cookies.get('PVELangCookie');
+ if (languageCookie === 'kr') {
+ // fix-up 'kr' being used for Korean by mistake FIXME: remove with PVE 9
+ let dt = Ext.Date.add(new Date(), Ext.Date.YEAR, 10);
+ languageCookie = 'ko';
+ Ext.util.Cookies.set('PVELangCookie', languageCookie, dt);
+ }
+ return languageCookie || Proxmox.defaultLang || 'en';
+ },
},
singleton: true,
lvmremove: ['Volume Group', gettext('Remove')],
lvmthincreate: [gettext('LVM-Thin Storage'), gettext('Create')],
lvmthinremove: ['Thinpool', gettext('Remove')],
- migrateall: ['', gettext('Migrate all VMs and Containers')],
+ migrateall: ['', gettext('Bulk migrate VMs and Containers')],
'move_volume': ['CT', gettext('Move Volume')],
'pbs-download': ['VM/CT', gettext('File Restore Download')],
pull_file: ['CT', gettext('Pull file')],
resize: ['VM/CT', gettext('Resize')],
spiceproxy: ['VM/CT', gettext('Console') + ' (Spice)'],
spiceshell: ['', gettext('Shell') + ' (Spice)'],
- startall: ['', gettext('Start all VMs and Containers')],
- stopall: ['', gettext('Stop all VMs and Containers')],
+ startall: ['', gettext('Bulk start VMs and Containers')],
+ stopall: ['', gettext('Bulk shutdown VMs and Containers')],
+ suspendall: ['', gettext('Suspend all VMs')],
unknownimgdel: ['', gettext('Destroy image from unknown guest')],
wipedisk: ['Device', gettext('Wipe Disk')],
vncproxy: ['VM/CT', gettext('Console')],