Skip to content

Cross-folder instrument utilization report#1253

Open
ankurjuneja wants to merge 3 commits into
developfrom
fb_1248_crossfolder
Open

Cross-folder instrument utilization report#1253
ankurjuneja wants to merge 3 commits into
developfrom
fb_1248_crossfolder

Conversation

@ankurjuneja

@ankurjuneja ankurjuneja commented Jul 1, 2026

Copy link
Copy Markdown
Contributor

Rationale

Users want to understand how a given instrument is utilized across every folder they can read, not just the folder they happen to be in. Today:

  • The instrument page (targetedms-showInstrument.view) is instrument-scoped but only lists sample files.
  • The utilization calendar (targetedms-qcSummaryHistory.view) shows files acquired, but it's folder-scoped and not instrument-filtered as it counts every instrument
    in the current folder.

This PR expands the existing Show Instrument page with two instrument-scoped, cross-folder views so utilization can be seen at a glance and analyzed as a table:

  • (A) a calendar heatmap of files acquired for that instrument across all readable folders, and
  • (B) a runs/files table by day, with a client-side toggle to summarize by month

Related Pull Requests

Changes

New queries (drive both the calendar and the grids; group SampleFile by acquisition day/month + InstrumentNickname):

  • resources/queries/targetedms/InstrumentUtilizationByDay.sql / .query.xml
  • resources/queries/targetedms/InstrumentUtilizationByMonth.sql / .query.xml

Controller — TargetedMSController.ShowInstrumentAction:

  • Added UtilizationByDay / UtilizationByMonth query-view branches, each with ContainerFilter.AllFolders + an InstrumentNickname filter (so counts span every readable
    folder for the selected instrument).
  • Added the "Utilization Calendar" and "Runs Acquired" views to the page, plus the InstrumentUtilizationBean that carries the two grid views into the JSP.

Views:

  • view/instrumentUtilizationCalendar.jsp — cross-folder heatmap (js-year-calendar), data via LABKEY.Query.selectRows with containerFilter: allFolders; defaults to 1 month.
  • view/instrumentUtilizationGrids.jsp — By Day / By Month toggle (client-side show/hide, no reload).

Tests (Selenium):

  • test/.../components/targetedms/InstrumentUtilizationWebPart.java — page object for the "Runs Acquired" web part.
  • test/.../tests/targetedms/TargetedMSInstrumentUtilizationTest.java — imports one document into two QC folders and asserts the By Day/By Month grids sum to 2× the single-folder file count, proving cross-folder aggregation; also checks the calendar renders and the toggle works.

ankurjuneja and others added 3 commits June 29, 2026 13:21
These generated view files were accidentally included in the cross-folder
instrument utilization commit and are unrelated to that feature.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@ankurjuneja ankurjuneja marked this pull request as ready for review July 6, 2026 16:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant