prune sim: show count for rule
and rename 'all zero' to 'keep-all' to make it consistent with the prune dialog in PBS. Signed-off-by: Fabian Ebner <f.ebner@proxmox.com>
This commit is contained in:
parent
984ac33d5c
commit
924d6d4072
|
@ -152,7 +152,12 @@ Ext.onReady(function() {
|
||||||
dataIndex: 'mark',
|
dataIndex: 'mark',
|
||||||
renderer: function(value, metaData, record) {
|
renderer: function(value, metaData, record) {
|
||||||
if (record.data.mark === 'keep') {
|
if (record.data.mark === 'keep') {
|
||||||
|
if (record.data.keepCount) {
|
||||||
|
return 'keep (' + record.data.keepName +
|
||||||
|
': ' + record.data.keepCount + ')';
|
||||||
|
} else {
|
||||||
return 'keep (' + record.data.keepName + ')';
|
return 'keep (' + record.data.keepName + ')';
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
return value;
|
return value;
|
||||||
}
|
}
|
||||||
|
@ -212,8 +217,12 @@ Ext.onReady(function() {
|
||||||
let text = Ext.Date.format(backup.data.backuptime, 'H:i');
|
let text = Ext.Date.format(backup.data.backuptime, 'H:i');
|
||||||
if (backup.data.mark === 'remove') {
|
if (backup.data.mark === 'remove') {
|
||||||
html += `<span class="strikethrough">${text}</span>`;
|
html += `<span class="strikethrough">${text}</span>`;
|
||||||
|
} else {
|
||||||
|
if (backup.data.keepCount) {
|
||||||
|
text += ` (${backup.data.keepName}: ${backup.data.keepCount})`;
|
||||||
} else {
|
} else {
|
||||||
text += ` (${backup.data.keepName})`;
|
text += ` (${backup.data.keepName})`;
|
||||||
|
}
|
||||||
if (me.useColors) {
|
if (me.useColors) {
|
||||||
let bgColor = COLORS[backup.data.keepName];
|
let bgColor = COLORS[backup.data.keepName];
|
||||||
let textColor = TEXT_COLORS[backup.data.keepName];
|
let textColor = TEXT_COLORS[backup.data.keepName];
|
||||||
|
@ -470,6 +479,7 @@ Ext.onReady(function() {
|
||||||
newlyIncludedCount++;
|
newlyIncludedCount++;
|
||||||
backup.mark = 'keep';
|
backup.mark = 'keep';
|
||||||
backup.keepName = keepName;
|
backup.keepName = keepName;
|
||||||
|
backup.keepCount = newlyIncludedCount;
|
||||||
} else {
|
} else {
|
||||||
backup.mark = 'remove';
|
backup.mark = 'remove';
|
||||||
}
|
}
|
||||||
|
@ -488,7 +498,7 @@ Ext.onReady(function() {
|
||||||
Number(keepParams['keep-yearly']) === 0) {
|
Number(keepParams['keep-yearly']) === 0) {
|
||||||
backups.forEach(function(backup) {
|
backups.forEach(function(backup) {
|
||||||
backup.mark = 'keep';
|
backup.mark = 'keep';
|
||||||
backup.keepName = 'all zero';
|
backup.keepName = 'keep-all';
|
||||||
});
|
});
|
||||||
|
|
||||||
return;
|
return;
|
||||||
|
|
Loading…
Reference in New Issue