diff --git a/CHANGELOG.md b/CHANGELOG.md index a7f6383d..538eda67 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,7 @@ - Check that provided d4 files when running queries using `/coverage/d4/genes/summary` endpoint are valid, with test - General report with coverage over the entire genome when no genes or genes panels are provided - A MANE coverage report, showing coverage and coverage completeness only on MANE transcripts for the provided list of genes +- Link out from MANE overview to gene overview ### Changed - Do not use stored cases/samples any more and run stats exclusively on d4 files paths provided by the user in real time - How parameters are passed to starlette.templating since it was raising a deprecation warning. diff --git a/src/chanjo2/endpoints/overview.py b/src/chanjo2/endpoints/overview.py index b0ef16ae..b14e06f1 100644 --- a/src/chanjo2/endpoints/overview.py +++ b/src/chanjo2/endpoints/overview.py @@ -141,13 +141,14 @@ async def demo_mane_overview( @router.post("/mane_overview", response_class=HTMLResponse) async def mane_overview( request: Request, + build=Annotated[Builds, Form(Builds.build_38)], samples=Annotated[str, Form(...)], + interval_type=Annotated[IntervalType, Form(IntervalType.TRANSCRIPTS)], completeness_thresholds=Annotated[Optional[str], Form(None)], ensembl_gene_ids=Annotated[Optional[str], Form(None)], hgnc_gene_ids=Annotated[Optional[str], Form(None)], hgnc_gene_symbols=Annotated[Optional[str], Form(None)], - case_display_name=Annotated[Optional[str], Form(None)], - panel_name=Annotated[Optional[str], Form("Custom panel")], + default_level=Annotated[Optional[int], Form(DEFAULT_COVERAGE_LEVEL)], db: Session = Depends(get_session), ): """Returns coverage overview stats for a group of samples over MANE transcripts of a list of genes.""" diff --git a/src/chanjo2/meta/handle_report_contents.py b/src/chanjo2/meta/handle_report_contents.py index c42a77d2..3d3f71a4 100644 --- a/src/chanjo2/meta/handle_report_contents.py +++ b/src/chanjo2/meta/handle_report_contents.py @@ -263,6 +263,7 @@ def get_mane_overview_coverage_stats(query: ReportQuery, session: Session) -> Di or query.hgnc_gene_symbols or query.ensembl_gene_ids, "interval_type": query.interval_type.value, + "default_level": query.default_level, "completeness_thresholds": query.completeness_thresholds, "samples": [_serialize_sample(sample) for sample in query.samples], "panel_name": query.panel_name, diff --git a/src/chanjo2/templates/mane-overview.html b/src/chanjo2/templates/mane-overview.html index 9f3ce519..fd211cde 100644 --- a/src/chanjo2/templates/mane-overview.html +++ b/src/chanjo2/templates/mane-overview.html @@ -27,6 +27,8 @@