Show log console for master and slaves in web UI

Rename InstanceConsole to LogConsole and use it to show logs for the
master server and slaves as well.
This commit is contained in:
Hornwitser committed 2021-10-31 10:41:25 +01:00
1 parent 7769c1f89e
commit 6e5e5f0aeb
6 files changed
+78 -32

No files matched your search

@@ -1,15 +1,23 @@
import React, { useContext } from "react";
import { Typography } from "antd";
import LogConsole from "./LogConsole";
import { useAccount } from "../model/account";
import MasterConfigTree from "./MasterConfigTree";
import PageLayout from "./PageLayout";
const { Title } = Typography;
export default function SlavesPage() {
let account = useAccount();
return <PageLayout nav={[{ name: "Master" }]}>
<h2>Master</h2>
{account.hasPermission("core.log.follow") && <>
<Title level={5} style={{ marginTop: 16 }}>Console</Title>
<LogConsole master={true} />
</>}
{account.hasPermission("core.master.get_config") && <MasterConfigTree />}
</PageLayout>;
};