Skip to content

Commit

Permalink
properly unblock datastores for sandbox
Browse files Browse the repository at this point in the history
  • Loading branch information
Feroze Mohideen committed May 14, 2024
1 parent a95f47d commit 5d3d5b6
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ const DatabaseDashboard: React.FC = () => {
}, [datastores, searchValue, typeFilter]);

const renderContents = (): JSX.Element => {
if (!currentProject?.db_enabled) {
if (!currentProject?.sandbox_enabled && !currentProject?.db_enabled) {
return (
<DashboardPlaceholder>
<Text size={16}>Datastores are not enabled for this project</Text>
Expand Down
6 changes: 6 additions & 0 deletions dashboard/src/main/home/sidebar/Sidebar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -319,6 +319,12 @@ class Sidebar extends Component<PropsType, StateType> {
<Img src={database} />
Datastores
</Container>
{match(currentProject)
.with({ sandbox_enabled: true }, () => <Badge>NEW</Badge>)
.with({ db_enabled: false }, () => (
<Image size={15} src={lock}></Image>
))
.otherwise(() => null)}
</Container>
</NavButton>
{!currentProject.sandbox_enabled && (
Expand Down

0 comments on commit 5d3d5b6

Please sign in to comment.