diff --git a/cdk/cdk-app.ts b/cdk/cdk-app.ts index ecc6b5326..cb97223dd 100644 --- a/cdk/cdk-app.ts +++ b/cdk/cdk-app.ts @@ -20,7 +20,7 @@ new AmplifyALBStack(app, 'stage-alb-stack', { new AmplifyALBStack(app, 'test-alb-stack', { stackName: 'test-alb-stack', dnsName: 'test', - targetInstanceId: 'i-003fafec7d050fd97', + targetInstanceId: 'i-0ccfdcd8c43104be5', env: { region: process.env.CDK_DEFAULT_REGION, account: process.env.CDK_DEFAULT_ACCOUNT, diff --git a/src/components/dataTable/AnnotatedEntitiesPopupCuration.js b/src/components/dataTable/AnnotatedEntitiesPopupCuration.js index 5da3e023f..3558ccf9c 100644 --- a/src/components/dataTable/AnnotatedEntitiesPopupCuration.js +++ b/src/components/dataTable/AnnotatedEntitiesPopupCuration.js @@ -92,11 +92,11 @@ function AnnotatedEntitiesPopupCuration({ children, entities, parentPage, mainRo {renderLink(entity)} - { parentPage === 'gene' || 'disease' ? : <>} + { parentPage === 'gene' || parentPage === 'disease' ? : <>} - { parentPage === 'gene' || 'disease' ? : <> } + { parentPage === 'gene' || parentPage === 'disease' ? : <> } diff --git a/src/components/dataTable/GeneticModifiersCellCuration.js b/src/components/dataTable/GeneticModifiersCellCuration.js index fc969aa93..80923132b 100644 --- a/src/components/dataTable/GeneticModifiersCellCuration.js +++ b/src/components/dataTable/GeneticModifiersCellCuration.js @@ -3,14 +3,16 @@ import { CollapsibleList } from '../collapsibleList'; import ExternalLink from '../ExternalLink'; import { getResourceUrl } from './getResourceUrl'; import { Link } from 'react-router-dom'; +import { getIdentifier } from './utils'; function GeneticModifierLink(modifier) { + const identifier = getIdentifier(modifier); switch(modifier?.type) { case 'Gene': if (modifier.geneSymbol) { return ( - + ); } @@ -18,13 +20,13 @@ function GeneticModifierLink(modifier) { case 'Allele': if (modifier.alleleSymbol) { return ( - + ); } break; case 'AffectedGenomicModel': - let url = getResourceUrl(modifier.curie, modifier.type, modifier.subtype); + let url = getResourceUrl(identifier, modifier.type, modifier.subtype); if (url && modifier.name) { return ( diff --git a/src/components/dataTable/StrainBackground.js b/src/components/dataTable/StrainBackground.js index f090b10cd..9854832b7 100644 --- a/src/components/dataTable/StrainBackground.js +++ b/src/components/dataTable/StrainBackground.js @@ -1,13 +1,16 @@ import ExternalLink from '../ExternalLink'; +import { getIdentifier } from './utils'; function StrainBackground({strainBackground}) { - if(strainBackground?.curie && strainBackground?.name) { - const strainName = ; - const strain = strainBackground.curie.slice('SGD:'.length); - return {strainName}; - } - return <>; + const indentifier = getIdentifier(strainBackground); + + if(!indentifier || !strainBackground?.name) return null; + + const strainName = ; + const strain = indentifier.slice('SGD:'.length); + + return {strainName}; } export default StrainBackground; diff --git a/src/components/dataTable/basedOnGeneCellCuration.js b/src/components/dataTable/basedOnGeneCellCuration.js index 7b5314997..96b33ff04 100644 --- a/src/components/dataTable/basedOnGeneCellCuration.js +++ b/src/components/dataTable/basedOnGeneCellCuration.js @@ -1,21 +1,22 @@ import { Link } from 'react-router-dom'; import { shortSpeciesName } from '../../lib/utils'; import { CollapsibleList } from '../../components/collapsibleList'; -import { removeDuplicates } from './utils'; +import { getIdentifier, removeDuplicates } from './utils'; import GeneSymbolCuration from '../GeneSymbolCuration'; +const GeneLink = ({ gene }) => { + const identifier = getIdentifier(gene); + return ( + + ({shortSpeciesName(gene.taxon.curie)}) + ); +}; const BasedOnGeneCellCuration = (genes) => { - if (!genes) { - return null; - } + if (!genes) return null; const uniqueGenes = removeDuplicates(genes, (gene) => gene.geneSymbol.displayText); return ( - {uniqueGenes.map(gene => ( - - ({shortSpeciesName(gene.taxon.curie)}) - - ))} + {uniqueGenes.map(gene => )} ); }; diff --git a/src/containers/layout/ReleaseBanner.js b/src/containers/layout/ReleaseBanner.js index dd0202306..786ec36ec 100644 --- a/src/containers/layout/ReleaseBanner.js +++ b/src/containers/layout/ReleaseBanner.js @@ -10,13 +10,13 @@ const ReleaseBanner = () => { isError, } = useRelease(); - const { releaseVersion, releaseDate } = releaseInfo || {}; + const { releaseVersion, snapShotDate } = releaseInfo || {}; return isLoading ? : ( Version: {isError ? 'Unknown' : releaseVersion}
- Date: { isError ? 'Unknown' : new Date(releaseDate).toDateString()} + Date: { isError ? 'Unknown' : new Date(snapShotDate).toDateString()}
); };