fix: ordering of operations when viewed from backup tree

This commit is contained in:
garethgeorge
2023-12-04 22:03:33 -08:00
parent 6665ad98d7
commit 063f086a6e
3 changed files with 6 additions and 2 deletions
-1
View File
@@ -15,7 +15,6 @@ import {
Typography,
} from "antd";
import {
ExclamationCircleOutlined,
PaperClipOutlined,
SaveOutlined,
DeleteOutlined,
+5
View File
@@ -124,6 +124,9 @@ export class BackupInfoCollector {
[...newInfo.operations, ...existing.operations],
(o) => o.id!
);
existing.operations.sort((a, b) => {
return parseInt(a.unixTimeStartMs!) - parseInt(b.unixTimeStartMs!);
});
if (newInfo.backupLastStatus) {
existing.backupLastStatus = newInfo.backupLastStatus;
}
@@ -264,6 +267,8 @@ export const displayTypeToString = (type: DisplayType) => {
return "Forget";
case DisplayType.PRUNE:
return "Prune";
case DisplayType.RESTORE:
return "Restore";
default:
return "Unknown";
}
+1 -1
View File
@@ -55,7 +55,7 @@ export const App: React.FC = () => {
style={{ color: colorTextLightSolid }}
onClick={() => setContent(null, [])}
>
ResticUI{" "}
BackRest<span style={{ color: "grey" }}>ic</span>{" "}
</a>
<small style={{ color: "rgba(255,255,255,0.3)", fontSize: "0.6em" }}>
{process.env.RESTICUI_BUILD_VERSION