defaultFocus: 'textarea[name=serializedinfo]',
isCreate: true,
- submitText: gettext('Join'),
+ bind: {
+ submitText: '{submittxt}',
+ },
showTaskViewer: true,
onlineHelp: 'pvecm_join_node_to_cluster',
} else {
return gettext("Default: IP resolved by node's hostname");
}
- }
- }
+ },
+ submittxt: function(get) {
+ let cn = get('info.clusterName');
+ if (cn) {
+ return `${gettext('Join')} '${cn}'`;
+ }
+ return gettext('Join');
+ },
+ },
},
controller: {
},
value: ''
},
- {
- xtype: 'textfield',
- fieldLabel: gettext('Cluster name'),
- readOnly: true,
- submitValue: false,
- bind: {
- hidden: '{!assistedEntry.checked}',
- value: '{info.clusterName}'
- },
- },
{
xtype: 'inputpanel',
column1: [