mirror of
https://git.proxmox.com/git/proxmox-widget-toolkit
synced 2025-05-11 19:42:49 +00:00
node/services: show masked and some unknown units as disabled (greyed out)
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
This commit is contained in:
parent
b6eedbba04
commit
89de7ec504
@ -10,6 +10,11 @@
|
|||||||
text-align: center;
|
text-align: center;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.proxmox-disabled-row, .proxmox-disabled-row td {
|
||||||
|
/*color: #a0a0a0;*/
|
||||||
|
color: #666665;
|
||||||
|
}
|
||||||
|
|
||||||
.proxmox-invalid-row {
|
.proxmox-invalid-row {
|
||||||
background-color: #f3d6d7;
|
background-color: #f3d6d7;
|
||||||
}
|
}
|
||||||
|
@ -147,6 +147,25 @@ Ext.define('Proxmox.node.ServiceView', {
|
|||||||
Proxmox.Utils.monStoreErrors(me, rstore);
|
Proxmox.Utils.monStoreErrors(me, rstore);
|
||||||
|
|
||||||
Ext.apply(me, {
|
Ext.apply(me, {
|
||||||
|
viewConfig: {
|
||||||
|
trackOver: false,
|
||||||
|
stripeRows: false, // does not work with getRowClass()
|
||||||
|
getRowClass: function(record, index) {
|
||||||
|
let unitState = record.get('unit-state');
|
||||||
|
if (!unitState) {
|
||||||
|
return '';
|
||||||
|
}
|
||||||
|
if (unitState === 'masked') {
|
||||||
|
return "proxmox-disabled-row";
|
||||||
|
} else if (unitState === 'unknown') {
|
||||||
|
if (record.get('name') === 'syslog') {
|
||||||
|
return "proxmox-disabled-row"; // replaced by journal on most hosts
|
||||||
|
}
|
||||||
|
return "proxmox-warning-row";
|
||||||
|
}
|
||||||
|
return '';
|
||||||
|
},
|
||||||
|
},
|
||||||
store: store,
|
store: store,
|
||||||
stateful: false,
|
stateful: false,
|
||||||
tbar: [start_btn, stop_btn, restart_btn, syslog_btn],
|
tbar: [start_btn, stop_btn, restart_btn, syslog_btn],
|
||||||
|
Loading…
Reference in New Issue
Block a user