Skip to content

[O2B-1536] Add lastEditiedBy name to EOR reason section of the run-details page#2090

Merged
graduta merged 14 commits intomainfrom
improv/O2B-1536/Add-lastEditiedBy-to-EOR-reason-on-run-details
Mar 5, 2026
Merged

[O2B-1536] Add lastEditiedBy name to EOR reason section of the run-details page#2090
graduta merged 14 commits intomainfrom
improv/O2B-1536/Add-lastEditiedBy-to-EOR-reason-on-run-details

Conversation

@isaachilly
Copy link
Collaborator

@isaachilly isaachilly commented Feb 26, 2026

I have a JIRA ticket

  • branch and/or PR name(s) include(s) JIRA ID
  • issue has "Fix version" assigned
  • issue "Status" is set to "In review"
  • PR labels are selected

Notable changes for users:

  • n/a

Notable changes for developers:

  • n/a

Changes made to the database:

  • n/a

Now display the lastEditedName for EOR reasons on `run-detail` page.

`formatEorReason` also renders a tooltip above the `lastEditedName` to make clear who it refers to.
Adjust expectations to include displayed author 'Anonymous' on a new line.
@isaachilly isaachilly self-assigned this Feb 26, 2026
@isaachilly isaachilly added frontend javascript Pull requests that update Javascript code labels Feb 26, 2026
@codecov
Copy link

codecov bot commented Feb 26, 2026

Codecov Report

❌ Patch coverage is 0% with 12 lines in your changes missing coverage. Please review.
✅ Project coverage is 45.56%. Comparing base (ecbbda0) to head (e62dbd2).
⚠️ Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
lib/public/views/Runs/format/formatRunEorReason.js 0.00% 5 Missing ⚠️
lib/public/views/Runs/format/editRunEorReasons.js 0.00% 3 Missing ⚠️
lib/public/views/Runs/Details/RunPatch.js 0.00% 2 Missing ⚠️
...b/public/views/Runs/Details/runDetailsComponent.js 0.00% 2 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #2090      +/-   ##
==========================================
- Coverage   45.58%   45.56%   -0.02%     
==========================================
  Files        1040     1041       +1     
  Lines       17310    17317       +7     
  Branches     3134     3136       +2     
==========================================
  Hits         7891     7891              
- Misses       9419     9426       +7     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Add a dedicated eorReasonComponent that renders the EOR reason VDOM.
Stop keeping a separate `eorReasonLastEditedNames` list on RunDetailsModel and instead include `lastEditedName` on each eorReason within RunPatch.

RunPatch `toPojo` then strips that field when building the outbound patch.

This removes duplicate state and ensures only allowed fields are sent to the server.
Rename eorReasonComponent to formatRunEorReason.

Return null instead of empty string for missing lastEditedName so the vdom doesn't render an empty node.
Adds a new test in that verifies the EOR reason popover shows the expected tooltip text.
@isaachilly isaachilly marked this pull request as ready for review March 5, 2026 12:33
@isaachilly isaachilly requested a review from graduta as a code owner March 5, 2026 12:33
Copy link
Member

@graduta graduta left a comment

Choose a reason for hiding this comment

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

PR looks good but I think we should take into consideration the wide-screen scenario as most of the screens at P2 are like that. Right now it is inconvenient to check left side screen with right side to see the author.

What do you think about bringing the author next to the EOR perhaps something like <eor_reason> added by ? Moreover, I think the tooltip does not need to be used in this proposal.

import { formatEorReason } from './formatEorReason.mjs';

/**
* Display the given EoR reason as a vdom component with lastEditedName tooltip
Copy link
Member

Choose a reason for hiding this comment

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

I am guessing you meant vnode instead of vdom?

@isaachilly
Copy link
Collaborator Author

isaachilly commented Mar 5, 2026

PR looks good but I think we should take into consideration the wide-screen scenario as most of the screens at P2 are like that. Right now it is inconvenient to check left side screen with right side to see the author.

What do you think about bringing the author next to the EOR perhaps something like <eor_reason> added by ? Moreover, I think the tooltip does not need to be used in this proposal.

In my opinion I think it is rare people are opening BKP at the wide-screens' full-width given the amount of whitespace and eye movement this causes with all the other UI elements not just EOR reasons section.

I also think if you add more onto this left side, we will have to redesign how EOR reasons appear as it would be 4 data points separated by dashes or even another way but still close together and at that point I think this is not good UX either. And redesigning is a larger ticket given this is so used etc.

Given you are already reading left to right, and it is never a huge list of reasons, then I thought a keeping to the right was okay.

Re the tooltip I thought it was useful just to reiterate to the user what this information was because I am unsure if they even know that EOR reasons are recorded with who created/editied them.

@graduta
Copy link
Member

graduta commented Mar 5, 2026

Very well then we continue like this. My comment on spacing was due to Filippo's recent comments on spacing in the filter boxes between label and input widgets as to there being too much white between them.
Please update the vdom -> vnode and then we are good to go

@isaachilly
Copy link
Collaborator Author

Very well then we continue like this. My comment on spacing was due to Filippo's recent comments on spacing in the filter boxes between label and input widgets as to there being too much white between them. Please update the vdom -> vnode and then we are good to go

I completely understand, for reference I add below what, very crudely, adding the name to the left side would look like.

Screenshot 2026-03-05 at 16 03 04

isaachilly and others added 3 commits March 5, 2026 16:06
…details' of github.com:AliceO2Group/Bookkeeping into improv/O2B-1536/Add-lastEditiedBy-to-EOR-reason-on-run-details
@graduta graduta merged commit cb698d6 into main Mar 5, 2026
22 of 24 checks passed
@graduta graduta deleted the improv/O2B-1536/Add-lastEditiedBy-to-EOR-reason-on-run-details branch March 5, 2026 15:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

frontend javascript Pull requests that update Javascript code

Development

Successfully merging this pull request may close these issues.

2 participants