Skip to content

Commit

Permalink
feat(#669): read genotype from lab if no lookup
Browse files Browse the repository at this point in the history
  • Loading branch information
tamslo committed Dec 29, 2023
1 parent f5f752c commit 115c576
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 7 deletions.
1 change: 0 additions & 1 deletion app/lib/report/pages/gene.dart
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,6 @@ class GenePage extends HookWidget {
final phenotypeText = phenotypeInformation.adaptionText.isNotNullOrBlank
? '${phenotypeInformation.phenotype}$drugInteractionIndicator'
: phenotypeInformation.phenotype;
if (phenotypeInformation.adaptionText.isNotNullOrBlank) {}
return _buildRow(
context.l10n.gene_page_phenotype,
phenotypeText,
Expand Down
16 changes: 10 additions & 6 deletions app/lib/report/pages/report.dart
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,16 @@ class ReportPage extends StatelessWidget {
final notTestedString = context.l10n.general_not_tested;
final userPhenotypes = CachedDrugs.instance.allGuidelineGenes.map(
(geneSymbol) => UserData.instance.lookups![geneSymbol] ??
CpicPhenotype(
geneSymbol: geneSymbol,
phenotype: notTestedString,
genotype: notTestedString,
lookupkey: notTestedString
)
// Add CpicPhenotype for unmatched lookup
CpicPhenotype(
geneSymbol: geneSymbol,
// phenotype will be overwritten with phenotype from lab or inhibited
// phenotype using PhenotypeInformation in GeneCard and GenePage
phenotype: notTestedString,
genotype: UserData.instance.diplotypes?[geneSymbol]?.genotype ??
notTestedString,
lookupkey: notTestedString
)
).sortedBy((phenotype) => phenotype.geneSymbol);
return PopScope(
canPop: false,
Expand Down

0 comments on commit 115c576

Please sign in to comment.