Added base handled for job decode and watcher start/top
This commit is contained in:
23
src/components/atoms/watcher-status/watcher-status.atom.jsx
Normal file
23
src/components/atoms/watcher-status/watcher-status.atom.jsx
Normal file
@@ -0,0 +1,23 @@
|
||||
import { Alert } from "antd";
|
||||
import React from "react";
|
||||
import { connect } from "react-redux";
|
||||
import { createStructuredSelector } from "reselect";
|
||||
import {
|
||||
selectWatcherError,
|
||||
selectWatcherStatus,
|
||||
} from "../../../redux/application/application.selectors";
|
||||
|
||||
const mapStateToProps = createStructuredSelector({
|
||||
watcherStatus: selectWatcherStatus,
|
||||
watcherError: selectWatcherError,
|
||||
});
|
||||
|
||||
export function WatcherStatusAtom({ watcherStatus, watcherError }) {
|
||||
return (
|
||||
<div>
|
||||
{watcherStatus}
|
||||
{watcherError && <Alert message={watcherError} />}
|
||||
</div>
|
||||
);
|
||||
}
|
||||
export default connect(mapStateToProps, null)(WatcherStatusAtom);
|
||||
Reference in New Issue
Block a user