UI for scheduling batch scripts#31885
Merged
Merged
Conversation
for #30526 # Details This PR updates the "Run batch script" modal to allow for scheduling scripts in the future. When a script is selected from the list, rather than running immediately, it now presents a choice of "Run now" and "Schedule for later". If the user opts to schedule for later, they are presented with a form for choosing the date and time to run the script. Run now example: https://github.com/user-attachments/assets/6fe3a77e-a271-4b58-abfd-c9ad9196d0b5 Schedule for later example: https://github.com/user-attachments/assets/ca43eab6-03f6-4c0b-929c-aabfb69f2e5f # Checklist for submitter ## Testing - [X] Added/updated automated tests - [X] QA'd all new/changed functionality manually
…s section, add new progress bar component (#31750) # #31224 and #31225 ## Summary * **New Features** * Introduced a modular Scripts management area with side navigation, including a "Script Library" and "Batch Progress" views. * Added a progress bar component with visual segments and Storybook/test coverage. * Implemented paginated batch execution summaries with status tabs, progress visualization, and detailed modal views. * Added new utility functions and endpoints to support script batch operations. * **Improvements** * Enhanced type safety and prop definitions for navigation and card components. * Improved documentation and comments for better clarity. * Updated routing to support section-based navigation within the Scripts area. * **Bug Fixes** * Corrected and unified types across hosts, scripts, and related components for batch status and summaries. ### Controls > Scripts > Batch progress   ### Progress bar component: <img width="265" height="852" alt="Screenshot 2025-08-08 at 5 13 12 PM" src="https://github.com/user-attachments/assets/d67ee2a1-c7db-4f0c-a856-ed5e45d65822" /> - [x] Changes file added for user-visible changes in `changes/` - [x] Added/updated automated tests - [x] QA'd all new/changed functionality manually --------- Co-authored-by: Jacob Shandling <jacob@fleetdm.com> Co-authored-by: Scott Gress <scott@fleetdm.com>
# Details This PR updates the current "batch script summary" modal to allow canceling the script directly from the modal. This is a first iteration of the cancelation feature which will be replaced by [the "batch script details" page](https://www.figma.com/design/Q18CcrFKmgOp0f5slpH35T/-28390-Schedule-scripts-to-run-at-a-specific-time?node-id=5861-25818&t=knTGlZtgFTj4NIUK-0). It also updates the modal to display the # of canceled items in the batch. # Checklist for submitter If some of the following don't apply, delete the relevant line. - [X] Changes file added for user-visible changes in `changes/`, `orbit/changes/` or `ee/fleetd-chrome/changes`. See [Changes files](https://github.com/fleetdm/fleet/blob/main/docs/Contributing/guides/committing-changes.md#changes-files) for more information. - [X] QA'd all new/changed functionality manually
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## main #31885 +/- ##
==========================================
+ Coverage 63.77% 63.79% +0.02%
==========================================
Files 1966 1970 +4
Lines 192570 192823 +253
Branches 6377 6358 -19
==========================================
+ Hits 122802 123006 +204
- Misses 60153 60202 +49
Partials 9615 9615
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
ghernandez345
approved these changes
Aug 14, 2025
BCTBB
pushed a commit
that referenced
this pull request
Aug 19, 2025
# Details This PR merges the feature branch for the scheduled scripts UI into main. This includes the following previously-approved PRs: * #31750 * #31604 * #31797 # Checklist for submitter If some of the following don't apply, delete the relevant line. - [X] Changes file added for user-visible changes in `changes/`, `orbit/changes/` or `ee/fleetd-chrome/changes`. See [Changes files](https://github.com/fleetdm/fleet/blob/main/docs/Contributing/guides/committing-changes.md#changes-files) for more information. ## Testing - [X] Added/updated automated tests - [X] Where appropriate, [automated tests simulate multiple hosts and test for host isolation](https://github.com/fleetdm/fleet/blob/main/docs/Contributing/reference/patterns-backend.md#unit-testing) (updates to one hosts's records do not affect another) - [X] QA'd all new/changed functionality manually --------- Co-authored-by: jacobshandling <61553566+jacobshandling@users.noreply.github.com> Co-authored-by: Jacob Shandling <jacob@fleetdm.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Details
This PR merges the feature branch for the scheduled scripts UI into main. This includes the following previously-approved PRs:
Checklist for submitter
If some of the following don't apply, delete the relevant line.
changes/,orbit/changes/oree/fleetd-chrome/changes.See Changes files for more information.
Testing
Added/updated automated tests
Where appropriate, automated tests simulate multiple hosts and test for host isolation (updates to one hosts's records do not affect another)
QA'd all new/changed functionality manually