mirror of
https://git.proxmox.com/git/proxmox-backup
synced 2025-04-28 09:54:35 +00:00

Add a maxLength in of 64*1024 in the frontend and the api. We allow a max body size of 512*1024 in the api (with patch [0]) so we should be fine. [0]: https://git.proxmox.com/?p=proxmox.git;a=commit;h=cf9e6c03a092acf8808ce83dad9249414fe4d588 Signed-off-by: Gabriel Goller <g.goller@proxmox.com> Link: https://lore.proxmox.com/20250410082052.53097-1-g.goller@proxmox.com
69 lines
1.6 KiB
JavaScript
69 lines
1.6 KiB
JavaScript
Ext.define('PBS.NodeOptionView', {
|
|
extend: 'Proxmox.grid.ObjectGrid',
|
|
alias: 'widget.pbsNodeOptionView',
|
|
|
|
monStoreErrors: true,
|
|
|
|
url: `/api2/json/nodes/${Proxmox.NodeName}/config`,
|
|
editorConfig: {
|
|
url: `/api2/extjs/nodes/${Proxmox.NodeName}/config`,
|
|
},
|
|
interval: 5000,
|
|
cwidth1: 200,
|
|
|
|
listeners: {
|
|
itemdblclick: function() { this.run_editor(); },
|
|
activate: function() { this.rstore.startUpdate(); },
|
|
destroy: function() { this.rstore.stopUpdate(); },
|
|
deactivate: function() { this.rstore.stopUpdate(); },
|
|
},
|
|
|
|
tbar: [
|
|
{
|
|
text: gettext('Edit'),
|
|
xtype: 'proxmoxButton',
|
|
disabled: true,
|
|
handler: btn => btn.up('grid').run_editor(),
|
|
},
|
|
],
|
|
|
|
gridRows: [
|
|
{
|
|
xtype: 'text',
|
|
name: 'http-proxy',
|
|
text: gettext('HTTP proxy'),
|
|
defaultValue: Proxmox.Utils.noneText,
|
|
vtype: 'HttpProxy',
|
|
deleteEmpty: true,
|
|
onlineHelp: 'node_options_http_proxy',
|
|
},
|
|
{
|
|
xtype: 'text',
|
|
name: 'email-from',
|
|
defaultValue: gettext('root@$hostname'),
|
|
text: gettext('Email from address'),
|
|
vtype: 'proxmoxMail',
|
|
deleteEmpty: true,
|
|
},
|
|
{
|
|
xtype: 'combobox',
|
|
name: 'default-lang',
|
|
text: gettext('Default Language'),
|
|
defaultValue: '__default__',
|
|
comboItems: Proxmox.Utils.language_array(),
|
|
deleteEmpty: true,
|
|
renderer: Proxmox.Utils.render_language,
|
|
},
|
|
{
|
|
xtype: 'textareafield',
|
|
name: 'consent-text',
|
|
text: gettext('Consent Text'),
|
|
deleteEmpty: true,
|
|
fieldOpts: {
|
|
maxLength: 64 * 1024,
|
|
},
|
|
onlineHelp: 'consent_banner',
|
|
},
|
|
],
|
|
});
|