Skip to content

Commit

Permalink
fix: kids-first#2993 new project
Browse files Browse the repository at this point in the history
  • Loading branch information
adipaul1981 committed Mar 23, 2021
1 parent 31a0558 commit b4040ca
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 5 deletions.
2 changes: 1 addition & 1 deletion src/pages/studies/SidebarFilters.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ const SidebarFilters: FC<SidebarData> = (sidebarData) => {
(f: any) => ({
data: {
count: f.doc_count,
key: keyEnhanceBooleanOnly(f.key).toLowerCase(),
key: keyEnhanceBooleanOnly(f.key),
},
name: keyEnhance(f.key),
id: f.key,
Expand Down
2 changes: 1 addition & 1 deletion src/pages/studies/studies.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ let previousMappingData: any | null = null;
const Studies: FC = () => {
const { filters } = useFilters();
let studiesResults = useGetStudiesPageData({ sqon: filters });
let studiesMappingResults = useGetExtendedMappings('study');
let studiesMappingResults = useGetExtendedMappings('Studies');

if (studiesResults.loading || studiesMappingResults.loadingMapping) {
if (!studiesResults.data && previousData) {
Expand Down
4 changes: 2 additions & 2 deletions src/store/graphql/studies/actions.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ export const useGetStudiesPageData = (variables: any): StudiesResults => {

return {
loading,
data: result?.study || null,
data: result?.Studies || null,
};
};

Expand All @@ -82,6 +82,6 @@ export const useGetExtendedMappings = (index: string): StudiesMappingResults =>

return {
loadingMapping: loading,
extendedMapping: result?.study.extended,
extendedMapping: result?.Studies.extended,
};
};
5 changes: 4 additions & 1 deletion src/store/graphql/studies/queries.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { fields } from './models';

export const STUDIES_QUERY = gql`
query StudiesInformation ($sqon: JSON){
study {
Studies {
hits(filters: $sqon) {
edges {
node {
Expand All @@ -14,6 +14,9 @@ export const STUDIES_QUERY = gql`
code
family_count
file_count
participant_count
data_access_authority
program
}
}
}
Expand Down

0 comments on commit b4040ca

Please sign in to comment.