Skip to content

Commit

Permalink
Merge pull request #207 from lsst-ts/tickets/DM-45327
Browse files Browse the repository at this point in the history
DM-45327: Handle empty historical days for cameras more elegantly
  • Loading branch information
ugyballoons authored Jul 24, 2024
2 parents 56c41a3 + abc435d commit ccee1ac
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 2 deletions.
1 change: 0 additions & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ dependencies = [
"uvicorn[standard]",
"pydantic_settings",
# Other dependencies.
"safir>=3.4.0",
"boto3",
"jinja2",
"websockets",
Expand Down
1 change: 1 addition & 0 deletions requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
# when using the Dockerfile on the root folder.
setuptools_scm
asgi_lifespan
structlog
boto3
fastapi
httpx
Expand Down
5 changes: 5 additions & 0 deletions src/js/components/TableApp.js
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,11 @@ export default function TableApp ({ camera, initialDate, initialChannelData, ini
}
}, [date]) // Only reattach the event listener if the date changes

if (Object.entries(metadata).length + Object.entries(channelData).length == 0) {
return (
<h3>There is no data for this day</h3>
)
}
return (
<div className="table-container">
<div className="above-table-sticky">
Expand Down
2 changes: 1 addition & 1 deletion src/js/components/TableView.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import React, { useEffect } from 'react'
import React from 'react'
import PropTypes from 'prop-types'
import { indicatorForAttr, _elWithClass, _elWithAttrs, replaceInString, _getById } from '../modules/utils'
import { metadatumType } from './componentPropTypes'
Expand Down

0 comments on commit ccee1ac

Please sign in to comment.