Skip to content

fix(ui): unknown date in bg task dialog box (#17140)#17142

Open
CelineSebe wants to merge 2 commits into
masterfrom
issue/17140
Open

fix(ui): unknown date in bg task dialog box (#17140)#17142
CelineSebe wants to merge 2 commits into
masterfrom
issue/17140

Conversation

@CelineSebe

@CelineSebe CelineSebe commented Jul 15, 2026

Copy link
Copy Markdown
Member

Proposed changes

  • formatting in dataTable toolbar .ISO

Related issues

How to test this PR

  1. Select an user in users list
  2. Click on Update paint button
  3. Select "Replace" in action type, " account lock date" in field (or password change date), select a date in time picker => click on OK
  4. Update
  5. Date is no longer "unknown"

Checklist

  • I consider the submitted work as finished
  • I tested the code for its functionality
  • I wrote test cases for the relevant use cases (coverage and e2e)
  • I added/updated the relevant documentation (either on GitHub or on Notion)
  • Where necessary, I refactored code to improve the overall quality

Further comments

Copilot AI review requested due to automatic review settings July 15, 2026 13:57
@github-actions github-actions Bot added the filigran team Item from the Filigran team. label Jul 15, 2026

Copilot AI 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.

Pull request overview

This PR addresses issue #17140 where date values configured via the DataTable background task “Update” dialog (notably user account expiration and password change dates) can display as “Unknown date”, by normalizing accepted picker values into ISO-8601 strings.

Changes:

  • Initialize the account_lock_after_date replace-field similarly to other date fields.
  • Normalize accepted DateTimePicker values to ISO strings in handleAcceptDate so downstream rendering/parsing doesn’t receive raw Date objects.

Comment on lines 620 to 622
} else if (value === 'password_valid_until' || value === 'account_lock_after_date') {
actionsInputs[i] = R.assoc('values', [new Date().toISOString()], actionsInputs[i] || {});
} else {
@codecov

codecov Bot commented Jul 15, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 0% with 9 lines in your changes missing coverage. Please review.
✅ Project coverage is 33.08%. Comparing base (6ad5834) to head (03d51bf).

Files with missing lines Patch % Lines
...t/src/private/components/data/DataTableToolBar.jsx 0.00% 9 Missing ⚠️

❌ Your patch check has failed because the patch coverage (0.00%) is below the target coverage (80.00%). You can increase the patch coverage or adjust the target coverage.

Additional details and impacted files
@@            Coverage Diff             @@
##           master   #17142      +/-   ##
==========================================
- Coverage   33.08%   33.08%   -0.01%     
==========================================
  Files        3323     3323              
  Lines      134679   134687       +8     
  Branches    36268    36272       +4     
==========================================
+ Hits        44560    44562       +2     
- Misses      90119    90125       +6     
Flag Coverage Δ
opencti-client-python 46.40% <ø> (ø)
opencti-front 9.79% <0.00%> (-0.01%) ⬇️
opencti-graphql 68.48% <ø> (+<0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 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.

@CelineSebe CelineSebe self-assigned this Jul 16, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

filigran team Item from the Filigran team.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

fix(bg-tasks): Dates for background tasks are unknown in dialog box

2 participants