[pve-devel] [PATCH manager 2/2] ui: firewall: Clarify text for "Add" button
Dominic Jäger
d.jaeger at proxmox.com
Tue Jan 5 12:00:33 CET 2021
The regular button is titled "Add". If groups are allowed, then the group
button is titled "Add: Group rule". In this case, changing the regular button
title to "Add: Rule" makes the difference a little more clear and also both
buttons then look the same.
Signed-off-by: Dominic Jäger <d.jaeger at proxmox.com>
---
www/manager6/grid/FirewallRules.js | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/www/manager6/grid/FirewallRules.js b/www/manager6/grid/FirewallRules.js
index 08deee2a..3ad41b10 100644
--- a/www/manager6/grid/FirewallRules.js
+++ b/www/manager6/grid/FirewallRules.js
@@ -529,7 +529,9 @@ Ext.define('PVE.FirewallRules', {
});
me.addBtn = Ext.create('Ext.Button', {
- text: gettext('Add'),
+ // Make difference between regular rule and group rule clear
+ text: gettext('Add') +
+ (me.allow_groups ? ": " + gettext('Rule') : ""),
disabled: true,
handler: function() {
var win = Ext.create('PVE.FirewallRuleEdit', {
--
2.20.1
More information about the pve-devel
mailing list