Skip to content

feat(FEAT-DATSET-09): show connected-dataset summary in project listing - #1490

Merged
sven1103 merged 9 commits into
developmentfrom
feature/display-datasets-after-login
Jul 30, 2026
Merged

feat(FEAT-DATSET-09): show connected-dataset summary in project listing#1490
sven1103 merged 9 commits into
developmentfrom
feature/display-datasets-after-login

Conversation

@sven1103

Copy link
Copy Markdown
Contributor

Summary

Implements Story #1475 / FEAT-DATSET-09: researchers can now see from their project collection dashboard whether each project has connected datasets, the quantity, the access-status breakdown (Open / Restricted), and when the most recent dataset was connected. Clicking the footer region navigates directly to the project's connected-datasets view (projects/{id}/datasets); clicking the card body still navigates to project info.

This is the UI/UX piece of FEAT-DATASET-CONNECTION. The connected-dataset aggregate itself (associated_dataset table, AssociatedDatasetService) is already provided by Story FEAT-DATSET-01 / PR #1483.

What changed

Area Change
sql/complete-schema.sql + sql/migrations/extend-dataset-visibility-in-project-overview.sql project_overview view extended with 4 aggregate columns (connectedDatasetCount, openDatasetCount, restrictedDatasetCount, lastConnectedOn) from a LEFT JOIN on associated_dataset. Migration is self-contained and idempotent (inlines measurement subqueries so it does not depend on project_measurements being previously refreshed).
project-management/.../ProjectOverview.java +4 fields mapping the new view columns; accessors added. Entity is @Immutable (read-only) so no constructor change required.
datamanager-app/.../ProjectCollectionComponent.java ProjectOverviewItem restructured: card body is a RouterLink (to ProjectInformationMain); footer is a separate RouterLink (to ConnectedDatasetsMain) as a sibling inside a .project-card-wrapper Div. No event-propagation hack — sibling <a> elements naturally don't fire each other's handlers. All layout uses theme classes; no inline getStyle().set(...) calls.
datamanager-app/frontend/.../page-area.css + all.css .project-card-wrapper owns the card's shadow/border-radius/margin. .project-dataset-footer provides top-border divider + hover/focus styles + chevron colour transition. Added .flex-shrink-0 utility to all.css.
docs/requirements.md New requirement IDs DATA-R-04, DATA-R-05, DATA-R-06 allocated for dataset connexion (existing DATA-R-01/02/03 for immunopeptidomics preserved; IDs are stable and never reused).
docs/plans/FEAT-DATSET-09-implementation-plan.md Implementation plan documenting phase-gating, the migration operator notes, and the CSS-class mapping audit.
datamanager-app/.../demo/ProjectListingDatasetsDemo.java Prototype sandbox retained under @Profile("development"), javadoc marked superseded; injected CSS stylesheet method removed (rules migrated into theme).

Requirements note

This PR adds new requirement IDs (DATA-R-04 / DATA-R-05 / DATA-R-06) and does not modify existing ones. Per AGENTS.md §11 ("requirement changes require human approval; dedicated PR"), the reviewer may prefer this change to be split into its own PR that touches docs/requirements.md only. If so, close this PR, open the requirements-only PR from this branch (sql/, Java, CSS revert), and rebase the UI work on top once requirements merge. Flagged as READY2CODE but gated on reviewer sign-off for this point.

Acceptance criteria from #1475

  • From each project entry, user can see whether that project has connected resources (footer hidden when count = 0)
  • From each project entry, user can see the quantity of connected resources (bold count)
  • From each project entry, user can see access status breakdown (Open / Restricted Tag pills)
  • Clicking into the project from the collection view navigates directly to the connected-datasets section (footer RouterLinkConnectedDatasetsMain)
  • Card body click still navigates to project info (no page-flash, no double-navigation) — verified by sibling-RouterLink structure
  • Last-connected date surfaced per project (stakeholder iteration, not original AC)

Operator actions required before deployment

  1. Apply the migration: sql/migrations/extend-dataset-visibility-in-project-overview.sql to the data_management datasource. Script is idempotent (DROP VIEW IF EXISTS + CREATE VIEW).
  2. Pre-flight checks: ensure associated_dataset table is already deployed (earlier create-associated-dataset.sql migration must have run).
  3. Rollback: drop and re-create project_overview from the pre-migration definition (see git show for the original view DDL).

Test plan

  • Run the app against a migrated dev DB; confirm project listing renders without SQL errors
  • Add a connected dataset to a project; refresh — footer appears with correct count / Tags / last-connected
  • Remove the dataset; footer disappears
  • Click card body → navigates to project info
  • Click footer → navigates to datasets view (no intermediate project-info page)
  • Keyboard: Tab through the listing; :focus-visible outline visible on footer
  • Screen reader: footer link has meaningful aria-label

Screenshots

(Add screenshots from test-view/project-listing-datasets under -Pdevelopment.)

Related

sven1103-agent and others added 2 commits June 26, 2026 08:46
* feat(haproxy): add custom 503 maintenance landing page

Add a branded HAProxy error page for 503 responses with:
- Inline SVG illustration (server rack scene with floating papers,
  smoke, and animated sparks/LEDs)
- Contact information and provider details
- Self-contained HTML+CSS (no external dependencies)

Fix HAProxy errorfile format requirements:
- Use HTTP/1.1 status line (required by HAProxy 2.7+)
- Include Content-Length header matching exact body size
- Use CRLF line endings throughout (RFC 7230)
- Keep body under HAProxy's 16KB error file limit

* Add file size constraint to docs

---------

Co-authored-by: Sven Fillinger <sven.fillinger@qbic.uni-tuebingen.de>
Story #1475 (FEAT-DATSET-09) — researchers can now see from their
project collection view whether each project has connected datasets,
how many, their access status (Open / Restricted), and when the most
recent dataset was connected. Clicking the footer navigates directly
to the project's ConnectedDatasetsMain view.

Changes:
- sql: extend project_overview view with 4 aggregate columns sourced
  from associated_dataset (COUNT, SUM PUBLIC, SUM RESTRICTED, MAX
  connected_on). Migration script is idempotent and self-contained
  — no cross-view dependency on project_measurements.
- project-management: +4 fields on ProjectOverview entity
- UI: card-body and footer rendered as sibling RouterLinks inside a
  project-card-wrapper Div so each click target drives exactly one
  navigation. Footer uses theme classes only (no inline styles).
- theme: .project-card-wrapper owns shadow/border-radius/margin;
  .project-overview-item provides card-body padding; .project-dataset-
  footer provides footer padding + hover affordance. Chevron turns
  primary-text-colour on hover.
- requirements: DATA-R-04/05/06 allocated (new IDs; existing 01-03
  for immunopeptidomics preserved).
- demo ProjectListingDatasetsDemo.java kept as development-profile
  prototype sandbox, javadoc marked superseded.

Refs: #1475, #1466 (FEAT-DATASET-CONNECTION)
@sven1103
sven1103 requested a review from a team as a code owner July 28, 2026 12:55
@sven1103 sven1103 linked an issue Jul 28, 2026 that may be closed by this pull request

@KochTobi KochTobi left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Very nice result. I found a couple of things I would ask you to look into.

  1. The usage of CSS !importan is unnecessary
  2. The way the feature formats dates and times might benefit from existing code. Please think about if you can use the existing formatting and feel free to state your reasons why not.
  3. One weird JavaDoc. Please clean it up 😄 many thanks!

String base = "Open datasets for %s: %d connected, %d open, %d restricted".formatted(
projectOverview.projectCode(), total, open, restricted);
if (lastConnected != null) {
String full = DateTimeFormatter.ofPattern("dd MMMM yyyy", Locale.ENGLISH)

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please have a look at life.qbic.application.commons.time.DateTimeFormat We have a class with applicable formatters.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think you forgot this.

Comment thread datamanager-app/frontend/themes/datamanager/components/page-area.css Outdated
Comment thread datamanager-app/frontend/themes/datamanager/components/page-area.css Outdated
Comment thread datamanager-app/frontend/themes/datamanager/components/all.css
@sven1103
sven1103 requested a review from KochTobi July 29, 2026 13:59

@KochTobi KochTobi left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You forgot one location for the data formatting. Otherwise looks awesome

text-overflow: ellipsis;
white-space: normal;
cursor: pointer;
text-decoration: none

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are you sure you need the text-decoration here? As far as I understood this was only regarding the footer which you already solved. By declaring it here, you disable the text-decoration for every project-overview-item (does the element with this class even have a different text-decoration?)

String base = "Open datasets for %s: %d connected, %d open, %d restricted".formatted(
projectOverview.projectCode(), total, open, restricted);
if (lastConnected != null) {
String full = DateTimeFormatter.ofPattern("dd MMMM yyyy", Locale.ENGLISH)

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think you forgot this.

Comment thread haproxy/README.md
@@ -0,0 +1,122 @@
# HAProxy Custom Error Pages

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why does this PR introduce the custom error pages? They were already included if I am not mistaken. Can you please double check?

@KochTobi KochTobi left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@sven1103
sven1103 merged commit 59a0b6b into development Jul 30, 2026
3 of 4 checks passed
@sven1103
sven1103 deleted the feature/display-datasets-after-login branch July 30, 2026 05:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Story] FEAT-DATSET-09: Access available datasets after login

3 participants