mirror of
https://git.proxmox.com/git/proxmox-backup
synced 2025-08-14 09:25:46 +00:00
gui: change reporting of the estimated_time_full to "Full" if no space
is left in the datastore. Before, the GUI would report "Never" for the estimated time full, because the value provided in the backend was in the past. To get around this, the GUI now reports "Full" if the value for available reaches 0. Signed-off-by: Daniel Tschlatscher <d.tschlatscher@proxmox.com>
This commit is contained in:
parent
de923258d0
commit
aaddf46a63
@ -285,7 +285,11 @@ Ext.define('PBS.Utils', {
|
||||
return tokenid.match(/^(.+)!([^!]+)$/)[2];
|
||||
},
|
||||
|
||||
render_estimate: function(value) {
|
||||
render_estimate: function(value, metaData, record) {
|
||||
if (record.data.avail === 0) {
|
||||
return gettext("Full");
|
||||
}
|
||||
|
||||
if (value === undefined) {
|
||||
return gettext('Not enough data');
|
||||
}
|
||||
|
@ -62,7 +62,8 @@ Ext.define('PBS.datastore.DataStoreListSummary', {
|
||||
let usagePanel = me.lookup('usage');
|
||||
usagePanel.updateValue(usage, usagetext);
|
||||
|
||||
let estimate = PBS.Utils.render_estimate(statusData['estimated-full-date']);
|
||||
let estimate = PBS.Utils.render_estimate(statusData['estimated-full-date'], null, { data: statusData });
|
||||
|
||||
vm.set('full', estimate);
|
||||
vm.set('deduplication', PBS.Utils.calculate_dedup_factor(statusData['gc-status']).toFixed(2));
|
||||
vm.set('stillbad', statusData['gc-status']['still-bad']);
|
||||
|
Loading…
Reference in New Issue
Block a user