]>
git.proxmox.com Git - pve-manager.git/blob - www/manager6/dc/OptionView.js
1 Ext
.define('PVE.dc.OptionView', {
2 extend
: 'Proxmox.grid.ObjectGrid',
3 alias
: ['widget.pveDcOptionView'],
5 onlineHelp
: 'datacenter_configuration_file',
9 initComponent : function() {
12 me
.add_combobox_row('keyboard', gettext('Keyboard Layout'), {
13 renderer
: PVE
.Utils
.render_kvm_language
,
14 comboItems
: PVE
.Utils
.kvm_keymap_array(),
15 defaultValue
: '__default__',
18 me
.add_text_row('http_proxy', gettext('HTTP proxy'), {
19 defaultValue
: Proxmox
.Utils
.noneText
,
23 me
.add_combobox_row('console', gettext('Console Viewer'), {
24 renderer
: PVE
.Utils
.render_console_viewer
,
25 comboItems
: PVE
.Utils
.console_viewer_array(),
26 defaultValue
: '__default__',
29 me
.add_text_row('email_from', gettext('Email from address'), {
32 defaultValue
: 'root@$hostname'
34 me
.add_text_row('mac_prefix', gettext('MAC address prefix'), {
36 defaultValue
: Proxmox
.Utils
.noneText
39 me
.selModel
= Ext
.create('Ext.selection.RowModel', {});
43 text
: gettext('Edit'),
44 xtype
: 'proxmoxButton',
46 handler: function() { me
.run_editor(); },
49 url
: "/api2/json/cluster/options",
51 url
: "/api2/extjs/cluster/options"
56 itemdblclick
: me
.run_editor
62 // set the new value for the default console
63 me
.mon(me
.rstore
, 'load', function(store
, records
, success
) {
68 var rec
= store
.getById('console');
69 PVE
.VersionInfo
.console
= rec
.data
.value
;
70 if (rec
.data
.value
=== '__default__') {
71 delete PVE
.VersionInfo
.console
;
75 me
.on('activate', me
.rstore
.startUpdate
);
76 me
.on('destroy', me
.rstore
.stopUpdate
);
77 me
.on('deactivate', me
.rstore
.stopUpdate
);