mirror of
https://git.proxmox.com/git/pmg-gui
synced 2025-08-07 09:42:55 +00:00
ClusterAdministration.js: code cleanup
This commit is contained in:
parent
c745a8755d
commit
ee138d2d4b
@ -11,6 +11,51 @@ Ext.define('pmg-cluster', {
|
|||||||
idProperty: 'cid'
|
idProperty: 'cid'
|
||||||
});
|
});
|
||||||
|
|
||||||
|
Ext.define('PMG.ClusterAddNodeWindow', {
|
||||||
|
extend: 'Ext.window.Window',
|
||||||
|
xtype: 'pmgClusterAddNodeWindow',
|
||||||
|
mixins: ['Proxmox.Mixin.CBind'],
|
||||||
|
|
||||||
|
width: 800,
|
||||||
|
|
||||||
|
modal: true,
|
||||||
|
|
||||||
|
title: gettext('Cluster Join Information'),
|
||||||
|
|
||||||
|
ipAddress: undefined,
|
||||||
|
|
||||||
|
fingerprint: undefined,
|
||||||
|
|
||||||
|
items: [
|
||||||
|
{
|
||||||
|
xtype: 'component',
|
||||||
|
border: false,
|
||||||
|
padding: 10,
|
||||||
|
html: gettext("Please use the 'Join' button on the node you want to add, using the following IP address and fingerprint.")
|
||||||
|
},
|
||||||
|
{
|
||||||
|
xtype: 'container',
|
||||||
|
layout: 'form',
|
||||||
|
border: false,
|
||||||
|
padding: '0 10 10 10',
|
||||||
|
items: [
|
||||||
|
{
|
||||||
|
xtype: 'textfield',
|
||||||
|
fieldLabel: gettext('IP Address'),
|
||||||
|
cbind: { value: '{ipAddress}' },
|
||||||
|
editable: false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
xtype: 'textfield',
|
||||||
|
fieldLabel: gettext('Fingerprint'),
|
||||||
|
cbind: { value: '{fingerprint}' },
|
||||||
|
editable: false
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
]
|
||||||
|
});
|
||||||
|
|
||||||
Ext.define('PMG.ClusterAdministration', {
|
Ext.define('PMG.ClusterAdministration', {
|
||||||
extend: 'Ext.tab.Panel',
|
extend: 'Ext.tab.Panel',
|
||||||
xtype: 'pmgClusterAdministration',
|
xtype: 'pmgClusterAdministration',
|
||||||
@ -54,38 +99,12 @@ Ext.define('PMG.ClusterAdministration', {
|
|||||||
|
|
||||||
onAdd: function() {
|
onAdd: function() {
|
||||||
var vm = this.getViewModel();
|
var vm = this.getViewModel();
|
||||||
var win = Ext.create('Ext.window.Window', {
|
|
||||||
width: 800,
|
var win = Ext.create('PMG.ClusterAddNodeWindow', {
|
||||||
modal: true,
|
ipAddress: vm.get('master').get('ip'),
|
||||||
title: gettext('Cluster Join Information'),
|
fingerprint: vm.get('master').get('fingerprint')
|
||||||
items: [
|
|
||||||
{
|
|
||||||
xtype: 'component',
|
|
||||||
border: false,
|
|
||||||
padding: 10,
|
|
||||||
html: gettext("Please use the 'Join' button on the node you want to add, using the following IP address and fingerprint.")
|
|
||||||
},
|
|
||||||
{
|
|
||||||
layout: 'form',
|
|
||||||
border: false,
|
|
||||||
padding: '0 10 10 10',
|
|
||||||
items: [
|
|
||||||
{
|
|
||||||
xtype: 'textfield',
|
|
||||||
fieldLabel: gettext('IP Address'),
|
|
||||||
value: vm.get('master').get('ip'),
|
|
||||||
editable: false
|
|
||||||
},
|
|
||||||
{
|
|
||||||
xtype: 'textfield',
|
|
||||||
fieldLabel: gettext('Fingerprint'),
|
|
||||||
value: vm.get('master').get('fingerprint'),
|
|
||||||
editable: false
|
|
||||||
}
|
|
||||||
]
|
|
||||||
}
|
|
||||||
]
|
|
||||||
});
|
});
|
||||||
|
|
||||||
win.show();
|
win.show();
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
Loading…
Reference in New Issue
Block a user