mirror of
https://git.proxmox.com/git/proxmox-widget-toolkit
synced 2025-05-21 21:29:07 +00:00
ui: SMART: show SMART data in correct columns
Signed-off-by: Matthias Heiserer <m.heiserer@proxmox.com>
This commit is contained in:
parent
f372d3c087
commit
aacb9ea12a
@ -38,12 +38,12 @@ Ext.define('Proxmox.window.DiskSmart', {
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
text: gettext('Value'),
|
text: gettext('Value'),
|
||||||
dataIndex: 'raw',
|
dataIndex: 'real-value',
|
||||||
renderer: Ext.String.htmlEncode,
|
renderer: Ext.String.htmlEncode,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
text: gettext('Normalized'),
|
text: gettext('Normalized'),
|
||||||
dataIndex: 'value',
|
dataIndex: 'real-normalized',
|
||||||
width: 60,
|
width: 60,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@ -154,7 +154,18 @@ Ext.define('Proxmox.window.DiskSmart', {
|
|||||||
Ext.define('pmx-smart-attribute', {
|
Ext.define('pmx-smart-attribute', {
|
||||||
extend: 'Ext.data.Model',
|
extend: 'Ext.data.Model',
|
||||||
fields: [
|
fields: [
|
||||||
{ name: 'id', type: 'number' }, 'name', 'value', 'worst', 'threshold', 'flags', 'fail', 'raw',
|
{ name: 'id', type: 'number' }, 'name', 'value', 'worst', 'threshold', 'flags', 'fail',
|
||||||
|
'raw', 'normalized',
|
||||||
|
{
|
||||||
|
name: 'real-value',
|
||||||
|
// FIXME remove with next major release (PBS 3.0)
|
||||||
|
calculate: data => (data.normalized ?? false) ? data.raw : data.value,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
name: 'real-normalized',
|
||||||
|
// FIXME remove with next major release (PBS 3.0)
|
||||||
|
calculate: data => data.normalized ?? data.raw,
|
||||||
|
},
|
||||||
],
|
],
|
||||||
idProperty: 'name',
|
idProperty: 'name',
|
||||||
});
|
});
|
||||||
|
Loading…
Reference in New Issue
Block a user