Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
28 commits
Select commit Hold shift + click to select a range
1696a5f
Adds Cypress directory to gitignore (Can be removed when ready)
BirdMachine Sep 18, 2025
73e01f4
Merge branch 'main' into datasetUpgrades
BirdMachine Sep 23, 2025
889a7cb
Merge Confict Resolution with popped Stash
BirdMachine Sep 23, 2025
af3c313
Additional Files from stash pop merge resolution
BirdMachine Sep 23, 2025
61454b3
Include new componentized Admin Task Asignment interface, fix Group v…
BirdMachine Sep 23, 2025
70e7a65
Adds Admin Task Assignment to formParts, Updates BulkSelector for han…
BirdMachine Sep 24, 2025
14bfead
Fix Duplicating entries in Dataset Type Dropdown, Expand Form Pre-fil…
BirdMachine Sep 24, 2025
28e06f1
Adds loading note feedback when BulkSelector is Being Populated at Lo…
BirdMachine Sep 24, 2025
5da2560
Fix Writability of Editable Dataset Data Type
BirdMachine Sep 24, 2025
9c970eb
Adaps casing for display subtypes on non-Dataset rows for Bulk Select…
BirdMachine Sep 24, 2025
af6f84e
Move form field & source Prefil management into formParts
BirdMachine Sep 24, 2025
b65ec44
adds group selector to Dataset Field Management, Managed Group field …
BirdMachine Sep 24, 2025
1c68d1c
Add Group Name to Form Header
BirdMachine Sep 26, 2025
5be0801
Simplify & Centralize state objects
BirdMachine Sep 26, 2025
6ed9602
Bulk Selector now honors URL Source List
BirdMachine Sep 26, 2025
f9f95d8
Cleans out redundant fucntions on formHelpers, Adds documenting comme…
BirdMachine Sep 26, 2025
6ab3630
Remove unused imports, fix spacing in new form header text
BirdMachine Sep 26, 2025
d888979
Remove Source List URL Handling (Moved into BulkSelector itself), fix…
BirdMachine Sep 26, 2025
9fbc12b
Moves Publications onto updates userGroup Select (Was using duplicate…
BirdMachine Sep 26, 2025
ad12d14
Fix Value setting of gene sequence radio, Properly capture error on E…
BirdMachine Sep 29, 2025
a758836
Allow for Custom Title and Subtitle on Bulk Selector, move Revert but…
BirdMachine Sep 29, 2025
5b24a06
Merge branch 'main' into datasetUpgrades
BirdMachine Sep 30, 2025
294f6a0
Fix Casing issue for Search Blacklist
BirdMachine Sep 30, 2025
745551b
Fix Casing for BulkSelector url-fill type validation of IDs
BirdMachine Sep 30, 2025
4f122c6
Restrictions fixes
BirdMachine Oct 1, 2025
7c38f32
Add Mouseover view of entityData.pipeline_message when mousing over s…
BirdMachine Oct 1, 2025
fffd771
Fix Group UUID being included with Process call, fix issue with permi…
BirdMachine Oct 3, 2025
febbcb0
Switch url uuid handling with entityData at Processing action
BirdMachine Oct 3, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ src/ingest-ui/.pnp.js
# testing
src/react-app/coverage
thunder-tests/
cypress/screenshots
cypress/*

# env files
src/.env.*
Expand Down
33 changes: 19 additions & 14 deletions src/src/App.js
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ import Forms from "./components/uuid/forms";
import {BuildError} from "./utils/error_helper";
import {Navigation} from "./Nav";
import Result from "./components/ui/result";
import SpeedDialTooltipOpen from './components/ui/formParts';
import {SpeedDialTooltipOpen} from './components/ui/formParts';
import {sortGroupsByDisplay,adminStatusValidation} from "./service/user_service";
import {api_validate_token} from './service/search_api';
import {ubkg_api_get_dataset_type_set,ubkg_api_get_organ_type_set} from "./service/ubkg_api";
Expand All @@ -50,6 +50,9 @@ import {DonorForm} from "./components/newDonor";
import {UploadForm} from "./components/newUpload";
import {SampleForm} from "./components/newSample";
import {PublicationForm} from "./components/newPublication";
import {DatasetForm} from "./components/newDataset";

import NotFound from "./components/404";

export function App(props){
let navigate = useNavigate();
Expand All @@ -67,8 +70,8 @@ export function App(props){
var[timerStatus, setTimerStatus] = useState(true);

// Data to fill in UI Elements
var[dataTypeList, setDataTypeList] = useState({}); //@TODO: Remove & use Local in forms
var[dataTypeListAll, setDataTypeListAll] = useState({}); //@TODO: Remove & use Local in forms
// var[dataTypeList, setDataTypeList] = useState({}); //@TODO: Remove & use Local in forms
// var[dataTypeListAll, setDataTypeListAll] = useState({}); //@TODO: Remove & use Local in forms
var[organList, setOrganList] = useState(); //@TODO: Remove & use Local in Search
// var [userDataGroups, setUserDataGroups] = useState({}); //@TODO: Remove & use Local in forms

Expand Down Expand Up @@ -131,8 +134,8 @@ export function App(props){
if(res !== undefined){
localStorage.setItem("datasetTypes",JSON.stringify(res));
// TODO: Eventually remove these & use localstorage
setDataTypeList(res);
setDataTypeListAll(res);
// setDataTypeList(res);
// setDataTypeListAll(res);
}else{
setAPIErr(["UBKG API : Dataset Types",'No local DATASET TYPE definitions were found and none could be fetched Please try again later, or contact [email protected]',res])
reportError(res)
Expand Down Expand Up @@ -527,10 +530,10 @@ export function App(props){
<Route path='donor' element={ <DonorForm onCreated={(response) => creationSuccess(response)}/>}/>
<Route path='sample' element={<SampleForm onCreated={(response) => creationSuccess(response)} /> }/>
<Route path='publication' element={<PublicationForm onCreated={(response) => creationSuccess(response)}/>} />
<Route path='collection' element={<RenderCollection dataGroups={JSON.parse(localStorage.getItem("userGroups"))} dtl_all={dataTypeList} newForm={true} reportError={reportError} groupsToken={groupsToken} onCreated={(response) => creationSuccess(response)} onReturn={() => onClose()} handleCancel={() => handleCancel()} /> }/>
<Route path='epicollection' element={<RenderEPICollection dataGroups={JSON.parse(localStorage.getItem("userGroups"))} dtl_all={dataTypeList} newForm={true} reportError={reportError} groupsToken={groupsToken} onCreated={(response) => creationSuccess(response)} onReturn={() => onClose()} handleCancel={() => handleCancel()} /> }/>
<Route path='collection' element={<RenderCollection dataGroups={JSON.parse(localStorage.getItem("userGroups"))} newForm={true} reportError={reportError} groupsToken={groupsToken} onCreated={(response) => creationSuccess(response)} onReturn={() => onClose()} handleCancel={() => handleCancel()} /> }/>
<Route path='epicollection' element={<RenderEPICollection dataGroups={JSON.parse(localStorage.getItem("userGroups"))} newForm={true} reportError={reportError} groupsToken={groupsToken} onCreated={(response) => creationSuccess(response)} onReturn={() => onClose()} handleCancel={() => handleCancel()} /> }/>
<Route path="dataset" element={<SearchComponent reportError={reportError} filter_type="Dataset" urlChange={(event, params, details) => urlChange(event, params, details)} routingMessage={routingMessage.Datasets} />} ></Route>
<Route path='datasetAdmin' element={<Forms reportError={reportError} formType='dataset' dataTypeList={dataTypeList} dtl_all={dataTypeList} dtl_primary={dataTypeList}new='true' onReturn={onClose} handleCancel={handleCancel} /> }/>
<Route path='datasetAdmin' element={<DatasetForm onCreated={(response) => creationSuccess(response)}/>}/>
<Route path='upload' element={ <UploadForm onCreated={(response) => creationSuccess(response)}/>}/>
{/* In Develpment here */}
</Route>
Expand All @@ -543,23 +546,25 @@ export function App(props){

<Route path="/donor/:uuid" element={<DonorForm onUpdated={(response) => updateSuccess(response)}/>} />
<Route path="/sample/:uuid" element={<SampleForm onUpdated={(response) => updateSuccess(response)}/>} />
<Route path="/dataset/:uuid" element={<RenderDataset reportError={reportError} dataTypeList={dataTypeList} handleCancel={handleCancel} allGroups={allGroups} status="view"/>} />
{/* <Route path="/upload/:uuid" element={<RenderUpload reportError={reportError} handleCancel={handleCancel} status="view" allGroups={allGroups}/>} /> */}
<Route path="/dataset/:uuid" element={<DatasetForm onUpdated={(response) => updateSuccess(response)}/>} />
<Route path="/upload/:uuid" element={ <UploadForm onUpdated={(response) => updateSuccess(response)}/>} />

<Route path="/publication/:uuid" element={<PublicationForm onUpdated={(response) => updateSuccess(response)} />} />
<Route path="/collection/:uuid" element={<RenderCollection groupsToken={groupsToken} dataGroups={JSON.parse(localStorage.getItem("userGroups"))} dtl_all={dataTypeListAll} onUpdated={(response) => updateSuccess(response)} reportError={reportError} handleCancel={handleCancel} status="view" />} />
<Route path="/epicollection/:uuid" element={<RenderEPICollection groupsToken={groupsToken} dataGroups={JSON.parse(localStorage.getItem("userGroups"))} dtl_all={dataTypeListAll} onUpdated={(response) => updateSuccess(response)} reportError={reportError} handleCancel={handleCancel} status="view" />} />
<Route path="/collection/:uuid" element={<RenderCollection groupsToken={groupsToken} dataGroups={JSON.parse(localStorage.getItem("userGroups"))} onUpdated={(response) => updateSuccess(response)} reportError={reportError} handleCancel={handleCancel} status="view" />} />
<Route path="/epicollection/:uuid" element={<RenderEPICollection groupsToken={groupsToken} dataGroups={JSON.parse(localStorage.getItem("userGroups"))} onUpdated={(response) => updateSuccess(response)} reportError={reportError} handleCancel={handleCancel} status="view" />} />

<Route path="/bulk/donors" exact element={<RenderBulk reportError={reportError} bulkType="donors" />} />
<Route path="/bulk/samples" exact element={<RenderBulk reportError={reportError} bulkType="samples" />} />

<Route path="/metadata">
<Route index element={<RenderMetadata reportError={reportError} type="block" />} />
<Route path='block' element={ <RenderMetadata reportError={reportError} type='block'/>}/>
<Route path='section' element={ <RenderMetadata reportError={reportError} type='section'/>}/>
<Route path='suspension' element={ <RenderMetadata reportError={reportError} type='suspension'/>}/>
</Route>

{/* In Develpment here */}
<Route path="/upload/:uuid" element={ <UploadForm onUpdated={(response) => updateSuccess(response)}/>} />
{/* 404 */}
<Route path="/notFound" element={ <NotFound /> } />

</Routes>

Expand Down
81 changes: 81 additions & 0 deletions src/src/components/404.jsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,81 @@
import React from "react";
import { Box, Typography, Button } from "@mui/material";
import WarningIcon from '@mui/icons-material/Warning';
import { useNavigate } from "react-router-dom";
import HealingIcon from '@mui/icons-material/Healing';
import KeyboardArrowRightIcon from '@mui/icons-material/KeyboardArrowRight';
import HomeIcon from '@mui/icons-material/Home';

export default function NotFound() {
const navigate = useNavigate();
const params = new URLSearchParams(window.location.search);
const entityID = params.get('entityID');
return (
<Box
sx={{
minHeight: "60vh",
display: "flex",
flexDirection: { xs: "column", sm: "row" },
alignItems: "stretch",
justifyContent: "center",
// border: "1px solid linear-gradient(180deg, #444a65 0%, #585e7a 100%)",
color: "#444a65",
borderRadius: "12px",
// boxShadow:0,
margin: "40px auto",
// maxWidth:
width:"100%",
padding: 4}}>
<Box
sx={{
flex: 1,
display: "flex",
flexDirection: "column",
alignItems: "flex-start",
justifyContent: "center",
pr: { sm: 4, xs: 0 },
color:"#ff005d",
borderRight: { sm: "2px solid #ff005d", xs: "none" },
mb: { xs: 3, sm: 0 }}}>
<Typography variant="h3" sx={{ fontWeight: "bold", mb: 1}}>
<HealingIcon sx={{ fontSize: 64, mb: 2 }} /> 404
</Typography>
<Typography variant="h5" sx={{ mb: 2 }}>
Entity Not Found
</Typography>
</Box>
<Box
sx={{
flex: 2,
display: "flex",
flexDirection: "column",
alignItems: "flex-start",
justifyContent: "center",
pl: { sm: 4, xs: 0 },
}}>
<Typography variant="body1" sx={{ mb: 3 }}>
Sorry, the Entity you are looking for {entityID ? (<Typography variant="caption" component="span" sx={{background:"#ff005d", color:"#fff", padding:"5px", borderRadius:"1em",fontWeight:"bold"}}>({entityID})</Typography>) : ""} was not found in neo4j. Please check the ID value again, return to the homepage, or try searching for it.
</Typography>
<Box sx={{ display: "flex", gap: 2 }}>
<Button
variant="contained"
startIcon={<HomeIcon />}
sx={{ background: "#444a65", color: "#fff", fontWeight: "bold" }}
onClick={() => navigate("/")}>
Go Home
</Button>
{/* {entityID && (
<Button
variant="outlined"
endIcon={<KeyboardArrowRightIcon />}
sx={{ color: "#444a65", borderColor:"#444a65", }}
onClick={() => navigate(`/?keywords=${entityID}`)}>
Search for {entityID}
</Button>
)} */}
</Box>

</Box>
</Box>
);
}
Empty file.
2 changes: 1 addition & 1 deletion src/src/components/collections.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ export const RenderCollection = (props) => {
editingCollection={entity_data}
// writeable={true}
dataGroups={dataGroups}
dtl_all={props.dtl_all}
dtl_all={localStorage.getItem("datasetTypes") ? JSON.parse(localStorage.getItem("datasetTypes")) : []}
newForm={ isNew ? true : null}
/>
</div>
Expand Down
2 changes: 1 addition & 1 deletion src/src/components/collections/collections.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ export function CollectionForm (props){
// Props
var [isNew] = useState(props.newForm);
var [dataGroups] = useState(props.dataGroups);
var [datatypeList] = useState(props.dtl_all);
// var [datatypeList] = useState(props.dtl_all);
var [editingCollection] = useState(props.editingCollection);


Expand Down
2 changes: 1 addition & 1 deletion src/src/components/epicollections.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ export const RenderEPICollection = (props) => {
editingCollection={entity_data}
// writeable={true}
dataGroups={dataGroups}
dtl_all={props.dtl_all}
dtl_all={localStorage.getItem("datasetTypes") ? JSON.parse(localStorage.getItem("datasetTypes")) : []}
newForm={ isNew ? true : null}
/>
</div>
Expand Down
Loading