This was already proposed by Dominik[0], but it was was wished for a
faster backend backing of this[1], and as with most wishes one needs
to either be content with what's there or (try) to improve it one
self.. So with the IPCC approach proposed as backing for this I'd
like to add this again. It differs from [0] a bit, first it's rebased
as parts of the tooltip stuff got already applied[2], and I choose to
use the same way we show it already in guest's config top bar, i.e.,
"🔒 (<LOCK>)" (lock symbol followed by lockname in parenthesis), no
hard feelings if it's seen better to use the original "Lock: <LOCK>"
formatting, though.

[0]: https://pve.proxmox.com/pipermail/pve-devel/2019-February/035829.html
[1]: https://pve.proxmox.com/pipermail/pve-devel/2019-March/035930.html
[2]: https://pve.proxmox.com/pipermail/pve-devel/2019-March/036165.html

Co-developed-by: Dominik Csapak <d.csa...@proxmox.com>
Signed-off-by: Thomas Lamprecht <t.lampre...@proxmox.com>
---
 www/manager6/tree/ResourceTree.js | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/www/manager6/tree/ResourceTree.js 
b/www/manager6/tree/ResourceTree.js
index 360e7e73..9ee7cbc7 100644
--- a/www/manager6/tree/ResourceTree.js
+++ b/www/manager6/tree/ResourceTree.js
@@ -137,6 +137,9 @@ Ext.define('PVE.tree.ResourceTree', {
        }
 
        var qtips = [gettext('Status') + ': ' + (info.qmpstatus || 
info.status)];
+       if (info.lock) {
+           qtips.push('<i class="fa fa-lg fa-lock"></i>' + ' (' + info.lock + 
')');
+       }
        if (info.hastate != 'unmanaged') {
            qtips.push(gettext('HA State') + ": " + info.hastate);
        }
-- 
2.20.1


_______________________________________________
pve-devel mailing list
pve-devel@pve.proxmox.com
https://pve.proxmox.com/cgi-bin/mailman/listinfo/pve-devel

Reply via email to