Skip to content

fix: simplify cronjob record duration display - #13398

Merged
ssongliu merged 1 commit into
dev-v2from
fix/cronjob-record-interval-display
Jul 29, 2026
Merged

fix: simplify cronjob record duration display#13398
ssongliu merged 1 commit into
dev-v2from
fix/cronjob-record-interval-display

Conversation

@ssongliu

Copy link
Copy Markdown
Member

Refs #13381

Copilot AI review requested due to automatic review settings July 28, 2026 09:49

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 updates the cronjob execution record UI to display task duration (interval) in a more human-readable format, aligning with the request in Issue #13381 to convert raw seconds/milliseconds into appropriate time units.

Changes:

  • Replaces inline ms vs s conditional rendering with a single formatInterval() formatter.
  • Adds a formatter that converts milliseconds into hour/minute/second components (with fractional seconds).

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread frontend/src/views/cronjob/cronjob/record/index.vue
Comment thread frontend/src/views/cronjob/cronjob/record/index.vue
@ssongliu
ssongliu force-pushed the fix/cronjob-record-interval-display branch from e61364a to 200e69c Compare July 29, 2026 02:55
Copilot AI review requested due to automatic review settings July 29, 2026 02:55
@ssongliu
ssongliu merged commit 4279339 into dev-v2 Jul 29, 2026
4 checks passed
@ssongliu
ssongliu deleted the fix/cronjob-record-interval-display branch July 29, 2026 02:57

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

Copilot reviewed 1 out of 1 changed files in this pull request and generated no new comments.

Comments suppressed due to low confidence (1)

frontend/src/views/cronjob/cronjob/record/index.vue:303

  • formatInterval hard-codes h/min/s unit suffixes, which bypasses existing i18n unit helpers used elsewhere (e.g. frontend/src/views/toolbox/clam/operate/index.vue:98-124 uses commons.units.*Unit). This will render English units even in non-English locales.
    return [
        hours ? `${hours}h` : '',
        minutes ? `${minutes}min` : '',
        seconds ? `${seconds}s` : '',
        milliseconds ? `${milliseconds}ms` : '',

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.

2 participants