Merge pull request #33 from dxos/egorgripasov-bot-logs

Display BotFactory logs.
This commit is contained in:
Thomas E Lackey 2020-07-20 10:26:53 -05:00 committed by GitHub
commit 87efdda548
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 8 additions and 0 deletions

View File

@ -11,8 +11,10 @@ import Panel from '../../../components/Panel';
import Toolbar from '../../../components/Toolbar';
import BotRecords from './BotRecords';
import LogPoller from '../../../components/LogPoller';
const TAB_RECORDS = 'records';
const TAB_LOG = 'log';
const useStyles = makeStyles(theme => ({
root: {}
@ -29,6 +31,7 @@ const Bots = () => {
<Toolbar>
<Tabs value={tab} onChange={(_, value) => setTab(value)}>
<Tab value={TAB_RECORDS} label='Records' />
<Tab value={TAB_LOG} label='Log' />
</Tabs>
</Toolbar>
}
@ -36,6 +39,10 @@ const Bots = () => {
{tab === TAB_RECORDS && (
<BotRecords />
)}
{tab === TAB_LOG && (
<LogPoller service='bot-factory' />
)}
</Panel>
);
};

View File

@ -30,6 +30,7 @@ const types = [
{ key: 'wrn:service', label: 'Service' },
{ key: 'wrn:app', label: 'App' },
{ key: 'wrn:bot', label: 'Bot' },
{ key: 'wrn:bot-factory', label: 'Bot Factory' },
{ key: 'wrn:type', label: 'Type' }
];