Commit c6c92fba authored by Markus Scheidgen's avatar Markus Scheidgen
Browse files

Fix missing entry list/delete button on empty uploads. #262.

parent b2225f86
......@@ -506,16 +506,20 @@ class Upload extends React.Component {
const { classes } = this.props
const { columns, upload } = this.state
const { calcs, tasks_status, waiting } = this.state.upload
if (!calcs) {
return (
<Typography className={classes.detailsContent}>
Loading ...
</Typography>
)
}
const { pagination } = calcs
if (pagination.total === 0 && tasks_status !== 'SUCCESS') {
if (!this.state.upload.tasks_running) {
return (
<Typography className={classes.detailsContent}>
No calculations to show.
</Typography>
)
} else {
if (this.state.upload.tasks_running) {
if (waiting) {
return (
<Typography className={classes.detailsContent}>
......@@ -617,7 +621,7 @@ class Upload extends React.Component {
Upload processing has errors: {errors.join(', ')}
</Typography> : ''
}
{upload.calcs ? this.renderCalcTable() : ''}
{this.renderCalcTable()}
{debug
? <div className={classes.detailsContent}>
<ReactJson src={upload} enableClipboard={false} collapsed={0} />
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment