Skip to content

Commit

Permalink
Merge pull request #69 from bhklab/mb-development
Browse files Browse the repository at this point in the history
Image modality changes
  • Loading branch information
mattbocc committed Oct 11, 2023
2 parents 8d6a7f1 + ac537b7 commit 8c2b83b
Show file tree
Hide file tree
Showing 5 changed files with 21 additions and 13 deletions.
4 changes: 2 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
api/package-lock.json
# package-lock.json
# package-lock.json
mock-pachyderm-api/node_modules
mock-pachyderm-api/package-lock.json
#api/pachyderm-config/pachyderm-config/
Expand All @@ -9,4 +9,4 @@ node_modules
old-db/db-scripts/data
db/data
.DS_Store
build
# build
2 changes: 1 addition & 1 deletion client/.gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# See https://help.github.com/articles/ignoring-files/ for more about ignoring files.
# See https://help.github.com/articles/ignoring-files/ for more about ignoring files.

# dependencies
/node_modules
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,14 +19,13 @@ const RadiomicSetTable = (props) => {
nameColumnTemplate,
downloadTemplate,
canonicalTemplate,
dataTypeTemplate,
availableDataTemplate
} = useDataTable(dataTypes.radiomics);

useEffect(()=>{
setState({...state, loading: false});
// eslint-disable-next-line react-hooks/exhaustive-deps
}, []);

return(
<DataTable
value={props.datasets}
Expand All @@ -37,11 +36,11 @@ const RadiomicSetTable = (props) => {
scrollable={true} scrollHeight={props.scrollHeight }
>
{props.authenticated && <Column selectionMode="multiple" style={{width: '30px', textAlign: 'center'}} />}
<Column className='textField' field='name' header='Name' style={{width:'150px'}} body={nameColumnTemplate} sortable={true} />
<Column className='textField' field='dataset.name' header='Dataset' style={{width:'100px'}} sortable={true} />
<Column field='availableDatatypes' body={dataTypeTemplate} style={{width:'100px'}} header='Image Modality' />
<Column field='canonical' body={canonicalTemplate} style={{width:'90px', textAlign: 'center'}} header='Canonical' />
<Column field='info.numDownload' style={{width:'100px', textAlign: 'center'}} header='Number of Downloads' sortable={true} />
<Column className='textField' field='name' header='Name' style={{width:'75px'}} body={nameColumnTemplate} sortable={true} />
<Column className='textField' field='dataset.name' header='Dataset' style={{width:'75px'}} sortable={true} />
<Column field="availableDatatypes" body={availableDataTemplate} style={{width:'75px'}} header='Image Modality' />
<Column field='canonical' body={canonicalTemplate} style={{width:'75px', textAlign: 'center'}} header='Canonical' />
<Column field='info.numDownload' style={{width:'25px', textAlign: 'center'}} header='Number of Downloads' sortable={true} />
{props.download && <Column field='downloadLink' body={downloadTemplate} style={{width:'60px', textAlign: 'center'}} header='Download' /> }
</DataTable>
);
Expand Down
11 changes: 10 additions & 1 deletion client/src/hooks/useDataTable.js
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,14 @@ const useDataTable = (datasetType) => {
</div>
);

const availableDataTemplate = (rowData, column) => {
return(
<div>
CT
</div>
);
}

const dataTypeTemplate = (rowData, column) => {
if(datasetType === dataTypes.pharmacogenomics){
return(
Expand Down Expand Up @@ -118,7 +126,8 @@ const useDataTable = (datasetType) => {
filteredTemplate,
canonicalTemplate,
sensitivityTemplate,
privateTemplate
privateTemplate,
availableDataTemplate
};

}
Expand Down
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 8c2b83b

Please sign in to comment.