-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #12 from SiriDB/development
Added error to failed jobs & added realtime config option
- Loading branch information
Showing
17 changed files
with
894 additions
and
203 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
REACT_APP_ENODO_HUB_URI="http://localhost:8001" | ||
REACT_APP_ENODO_HUB_URI="http://localhost" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
import React from 'react'; | ||
import Button from '@material-ui/core/Button'; | ||
import Dialog from '@material-ui/core/Dialog'; | ||
import DialogActions from '@material-ui/core/DialogActions'; | ||
import DialogContent from '@material-ui/core/DialogContent'; | ||
import DialogContentText from '@material-ui/core/DialogContentText'; | ||
import DialogTitle from '@material-ui/core/DialogTitle'; | ||
|
||
export default function ErrorDialog({open, handleClose, error}) { | ||
|
||
return ( | ||
<Dialog | ||
open={open} | ||
onClose={handleClose} | ||
> | ||
<DialogTitle>{"Error"}</DialogTitle> | ||
<DialogContent> | ||
<DialogContentText> | ||
{error} | ||
</DialogContentText> | ||
</DialogContent> | ||
<DialogActions> | ||
<Button onClick={handleClose} color='primary'> | ||
{'Close'} | ||
</Button> | ||
</DialogActions> | ||
</Dialog> | ||
); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
import React from "react"; | ||
|
||
import SerieConfigurator from '../Serie/SerieConfigurator'; | ||
import { socket } from '../../store'; | ||
|
||
export default function AddLabelDialog({ handleClose }) { | ||
|
||
const onSubmit = (config) => { | ||
socket.emit('/api/enodo/labels/create', config, () => { | ||
handleClose(); | ||
}); | ||
}; | ||
|
||
return ( | ||
<SerieConfigurator | ||
title='Add label' | ||
onSubmit={onSubmit} | ||
onClose={handleClose} | ||
dialog='addLabel' | ||
/> | ||
); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
import React from "react"; | ||
|
||
import SerieConfigurator from '../Serie/SerieConfigurator'; | ||
|
||
export default function ConfigDialog({ handleClose, label }) { | ||
|
||
return ( | ||
<SerieConfigurator | ||
title='Label configuration' | ||
onClose={handleClose} | ||
dialog='infoLabel' | ||
currentConfig={label} | ||
/> | ||
); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
import React from 'react'; | ||
import Button from '@material-ui/core/Button'; | ||
import Dialog from '@material-ui/core/Dialog'; | ||
import DialogActions from '@material-ui/core/DialogActions'; | ||
import DialogContent from '@material-ui/core/DialogContent'; | ||
import DialogContentText from '@material-ui/core/DialogContentText'; | ||
import DialogTitle from '@material-ui/core/DialogTitle'; | ||
|
||
import { socket } from '../../store'; | ||
|
||
export default function DeleteLabelDialog({ open, handleClose, selectedLabel }) { | ||
|
||
const onDelete = () => { | ||
const data = { selector: selectedLabel.name }; | ||
socket.emit('/api/enodo/labels/delete', data, () => { | ||
handleClose(); | ||
}); | ||
}; | ||
|
||
return ( | ||
<Dialog | ||
open={open} | ||
onClose={handleClose} | ||
> | ||
<DialogTitle>{'Delete label?'}</DialogTitle> | ||
<DialogContent> | ||
<DialogContentText> | ||
{'Are you sure you want to delete this label? This results in the removal of all related series from Enodo.'} | ||
</DialogContentText> | ||
</DialogContent> | ||
<DialogActions> | ||
<Button onClick={handleClose}> | ||
{'Cancel'} | ||
</Button> | ||
<Button onClick={onDelete} color="primary"> | ||
{'Confirm'} | ||
</Button> | ||
</DialogActions> | ||
</Dialog> | ||
); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.