* [PATCH manager 1/4] ui: form: list field: don't modify the class definition
2026-11-05 12:53 [PATCH manager 0/4] ui: small fixes for tag editing Dominik Csapak
@ 2026-11-05 12:53 ` Dominik Csapak
2026-11-05 12:53 ` [PATCH manager 2/4] ui: form: list field: fix type for header text assignment Dominik Csapak
` (3 subsequent siblings)
4 siblings, 0 replies; 6+ messages in thread
From: Dominik Csapak @ 2026-11-05 12:53 UTC (permalink / raw)
To: pve-devel
Modifying a property defined on the class level modifies the prototype
of that class. This can have unintended consequences when only part of
the config is used in some widgets.
This can be seen here with the `Registered Tags` and `User Tag Access`
lists: One has no emptytext while the other does. Opening them in an
alternating fashion adds the empty text from one to the other.
Fix it by constructing the initial items list in initComponent, and let
the widget modify that instead.
Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
---
www/manager6/form/ListField.js | 46 +++++++++++++++++-----------------
1 file changed, 23 insertions(+), 23 deletions(-)
diff --git a/www/manager6/form/ListField.js b/www/manager6/form/ListField.js
index 49651bc5..6fcbdfd8 100644
--- a/www/manager6/form/ListField.js
+++ b/www/manager6/form/ListField.js
@@ -124,34 +124,34 @@ Ext.define('PVE.form.ListField', {
},
},
- items: [
- {
- xtype: 'grid',
- reference: 'grid',
+ initComponent: function () {
+ let me = this;
- viewConfig: {
- deferEmptyText: false,
- },
+ me.items = [
+ {
+ xtype: 'grid',
+ reference: 'grid',
- store: {
- listeners: {
- update: function () {
- this.commitChanges();
+ viewConfig: {
+ deferEmptyText: false,
+ },
+
+ store: {
+ listeners: {
+ update: function () {
+ this.commitChanges();
+ },
},
},
},
- },
- {
- xtype: 'button',
- text: gettext('Add'),
- iconCls: 'fa fa-plus-circle',
- handler: 'addLine',
- margin: '5 0 0 0',
- },
- ],
-
- initComponent: function () {
- let me = this;
+ {
+ xtype: 'button',
+ text: gettext('Add'),
+ iconCls: 'fa fa-plus-circle',
+ handler: 'addLine',
+ margin: '5 0 0 0',
+ },
+ ];
for (const [key, value] of Object.entries(me.gridConfig ?? {})) {
me.items[0][key] = value;
--
2.47.3
^ permalink raw reply related [flat|nested] 6+ messages in thread* [PATCH manager 2/4] ui: form: list field: fix type for header text assignment
2026-11-05 12:53 [PATCH manager 0/4] ui: small fixes for tag editing Dominik Csapak
2026-11-05 12:53 ` [PATCH manager 1/4] ui: form: list field: don't modify the class definition Dominik Csapak
@ 2026-11-05 12:53 ` Dominik Csapak
2026-11-05 12:53 ` [PATCH manager 3/4] ui: dc: options: add emptytext to user tag access edit grid Dominik Csapak
` (2 subsequent siblings)
4 siblings, 0 replies; 6+ messages in thread
From: Dominik Csapak @ 2026-11-05 12:53 UTC (permalink / raw)
To: pve-devel
it's `fieldTitle` not `fieldTtitle`. This had the effect that no header
was shown, since no column had one. With this fix, the header is now
shown.
Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
---
www/manager6/form/ListField.js | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/www/manager6/form/ListField.js b/www/manager6/form/ListField.js
index 6fcbdfd8..3152c626 100644
--- a/www/manager6/form/ListField.js
+++ b/www/manager6/form/ListField.js
@@ -159,7 +159,7 @@ Ext.define('PVE.form.ListField', {
me.items[0].columns = [
{
- header: me.fieldTtitle,
+ header: me.fieldTitle,
dataIndex: 'item',
xtype: 'widgetcolumn',
widget: {
--
2.47.3
^ permalink raw reply related [flat|nested] 6+ messages in thread* [PATCH manager 3/4] ui: dc: options: add emptytext to user tag access edit grid
2026-11-05 12:53 [PATCH manager 0/4] ui: small fixes for tag editing Dominik Csapak
2026-11-05 12:53 ` [PATCH manager 1/4] ui: form: list field: don't modify the class definition Dominik Csapak
2026-11-05 12:53 ` [PATCH manager 2/4] ui: form: list field: fix type for header text assignment Dominik Csapak
@ 2026-11-05 12:53 ` Dominik Csapak
2026-11-05 12:53 ` [PATCH manager 4/4] ui: dc options: add missing field title to registered tag " Dominik Csapak
2026-11-05 23:44 ` applied: [PATCH manager 0/4] ui: small fixes for tag editing Thomas Lamprecht
4 siblings, 0 replies; 6+ messages in thread
From: Dominik Csapak @ 2026-11-05 12:53 UTC (permalink / raw)
To: pve-devel
This was missing but sometimes accidentally included due to a bug in the
list component. Add it to be consistent with the registered tags edit
window.
Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
---
www/manager6/dc/UserTagAccessEdit.js | 1 +
1 file changed, 1 insertion(+)
diff --git a/www/manager6/dc/UserTagAccessEdit.js b/www/manager6/dc/UserTagAccessEdit.js
index 9d0fe13b..f2c74c89 100644
--- a/www/manager6/dc/UserTagAccessEdit.js
+++ b/www/manager6/dc/UserTagAccessEdit.js
@@ -75,6 +75,7 @@ Ext.define('PVE.dc.UserTagAccessEdit', {
gridConfig: {
height: 200,
scrollable: true,
+ emptyText: gettext('No Tags defined'),
},
listeners: {
change: 'tagChange',
--
2.47.3
^ permalink raw reply related [flat|nested] 6+ messages in thread* [PATCH manager 4/4] ui: dc options: add missing field title to registered tag edit grid
2026-11-05 12:53 [PATCH manager 0/4] ui: small fixes for tag editing Dominik Csapak
` (2 preceding siblings ...)
2026-11-05 12:53 ` [PATCH manager 3/4] ui: dc: options: add emptytext to user tag access edit grid Dominik Csapak
@ 2026-11-05 12:53 ` Dominik Csapak
2026-11-05 23:44 ` applied: [PATCH manager 0/4] ui: small fixes for tag editing Thomas Lamprecht
4 siblings, 0 replies; 6+ messages in thread
From: Dominik Csapak @ 2026-11-05 12:53 UTC (permalink / raw)
To: pve-devel
This header wasn't shown by accident, so it never surfaced that this was
missing. Since the header is now visible, add the proper title.
Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
---
www/manager6/dc/RegisteredTagsEdit.js | 1 +
1 file changed, 1 insertion(+)
diff --git a/www/manager6/dc/RegisteredTagsEdit.js b/www/manager6/dc/RegisteredTagsEdit.js
index 29aefa28..6e93c223 100644
--- a/www/manager6/dc/RegisteredTagsEdit.js
+++ b/www/manager6/dc/RegisteredTagsEdit.js
@@ -54,6 +54,7 @@ Ext.define('PVE.dc.RegisteredTagsEdit', {
{
name: 'tags',
xtype: 'pveListField',
+ fieldTitle: gettext('Tag'),
maskRe: PVE.Utils.tagCharRegex,
gridConfig: {
height: 200,
--
2.47.3
^ permalink raw reply related [flat|nested] 6+ messages in thread* applied: [PATCH manager 0/4] ui: small fixes for tag editing
2026-11-05 12:53 [PATCH manager 0/4] ui: small fixes for tag editing Dominik Csapak
` (3 preceding siblings ...)
2026-11-05 12:53 ` [PATCH manager 4/4] ui: dc options: add missing field title to registered tag " Dominik Csapak
@ 2026-11-05 23:44 ` Thomas Lamprecht
4 siblings, 0 replies; 6+ messages in thread
From: Thomas Lamprecht @ 2026-11-05 23:44 UTC (permalink / raw)
To: pve-devel, Dominik Csapak
On Thu, 05 Nov 2026 13:53:17 +0100, Dominik Csapak wrote:
> Some small issues noticed when looking for the same issue as [0].
>
> 0: https://lore.proxmox.com/pve-devel/0c0f6a2b-b475-4f41-9342-c0d4ae94becc@inrae.fr/
>
> Dominik Csapak (4):
> ui: form: list field: don't modify the class definition
> ui: form: list field: fix type for header text assignment
> ui: dc: options: add emptytext to user tag access edit grid
> ui: dc options: add missing field title to registered tag edit grid
>
> [...]
Applied, thanks!
With some changes on top:
I squashed 4/4 into 2/4, since the typo fix is what makes the default
"Item" header visible in the first place.
3/4 now moves the empty text instead of adding a second one. The
emptyText on the list field itself is ignored, it was left behind when
56dee217b ("ui: fix datacenter tags options inputs") moved the one for
registered tags into the grid config.
I also shortened the commit messages and merged some prefix levels.
In 1/4 I dropped the "alternating": opening Registered Tags once is
enough for User Tag Access to also show the empty text until the next
page reload.
[1/4] ui: form: list field: don't modify the class definition
https://git.proxmox.com/?p=pve-manager.git;a=commitdiff;h=7520a9b701607ba8a489e50fc61180784947c1f5
[2/4] ui: form: list field: fix type for header text assignment
https://git.proxmox.com/?p=pve-manager.git;a=commitdiff;h=8eaa8a7406bd9f25177141f277d84f97b9033b0e
[3/4] ui: dc: options: add emptytext to user tag access edit grid
https://git.proxmox.com/?p=pve-manager.git;a=commitdiff;h=9cc05ac0b47b9ffd383b7de016f4445b17d9bdd0
[4/4] ui: dc options: add missing field title to registered tag edit grid
https://git.proxmox.com/?p=pve-manager.git;a=commitdiff;h=8eaa8a7406bd9f25177141f277d84f97b9033b0e
^ permalink raw reply [flat|nested] 6+ messages in thread