Skip to content
Snippets Groups Projects
Commit 11ef04ab authored by Remi  PLANEL's avatar Remi PLANEL
Browse files

less restrictive research if cannot found mapping between DF model gene name...

less restrictive research if cannot found mapping between DF model gene name and structure gene name
parent af7fb909
No related branches found
No related tags found
No related merge requests found
Pipeline #129394 failed
......@@ -63,7 +63,18 @@ const sanitizedHits = computed<StructureOperonGeneWithImg[]>(() => {
const genesAndSynonymous = new Set([sanitizedGene, ...sanitizedExangeableGenes])
if (monomerStructuresVal) {
const struct = monomerStructuresVal.find((struct) => {
return genesAndSynonymous.has(struct.proteins_in_the_prediction[0])
const hasInSet = genesAndSynonymous.has(struct.proteins_in_the_prediction[0])
if (hasInSet) return hasInSet
// try some less restrictive search
return Array.from(genesAndSynonymous).find(dfModelGeneName => {
if (dfModelGeneName !== undefined && struct?.proteins_in_the_prediction !== undefined) {
const protName = struct.proteins_in_the_prediction[0]
if (protName !== undefined) return dfModelGeneName.startsWith(protName)
}
return false
}) !== undefined
})
const rawImgUrl = joinURL(`/${system.toLowerCase()}`, struct?.structImg ?? '')
const rawStructUrl = joinURL(`/${system.toLowerCase()}`, struct?.structPath ?? '')
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment