Skip to content

[Feat] Add cron tasks management UI (#161)#161

Merged
samzong merged 1 commit intomainfrom
feat/cron-tasks-ui
Mar 24, 2026
Merged

[Feat] Add cron tasks management UI (#161)#161
samzong merged 1 commit intomainfrom
feat/cron-tasks-ui

Conversation

@samzong
Copy link
Copy Markdown
Collaborator

@samzong samzong commented Mar 24, 2026

Summary

Full cron job management panel for ClawWork — create, edit, delete, toggle, run, and monitor recurring agent tasks directly from the desktop client.

Type of change

  • [Feat] new feature
  • [UI] UI or UX change

Why is this needed?

OpenClaw Gateway exposes a rich cron scheduling system (cron.* RPCs) but ClawWork had no UI for it. Users had to manage cron jobs via CLI or raw API calls. This PR adds a first-class scheduling interface as a main area view.

What changed?

  • CronPanel — main area view with job list, filter tabs (All/Enabled/Disabled), search, gateway selector with scheduler status indicator, pagination
  • CronJobDialog — create/edit dialog with cron expression presets (every 5 min, hourly, daily 9 AM, weekdays 9 AM, every Monday), human-readable preview via cronstrue, interval unit selector (minutes/hours/days), advanced options (model, thinking, delivery, failure alerts)
  • CronJobCard — job card with toggle, status dot, schedule badge, action buttons (run, history, edit, delete)
  • CronRunHistory — inline run history table per job with expandable summary/error, Open Task navigation
  • Session identity fix — cron jobs now use store-key format (agent:main:clawwork:<deviceId>:task:<uuid>) and register a local task on creation, so cron-created conversations appear in the task list and events route correctly
  • deleteAfterRun fix — explicitly send false to prevent server defaulting one-shot jobs to auto-delete
  • Titlebar drag fix — removed global fixed z-50 overlay from App.tsx; each panel header owns its own drag region via titlebar-drag class, eliminating recurring z-index bugs
  • Removed request-key infrastructurebuildSessionRequestKey, request-key regexes, and related code removed from shared/constants since store-key format is now used consistently
  • All filter fix — send enabled: 'all' explicitly to server instead of undefined (server defaults to enabled-only)

Architecture impact

  • Owning layer: shared / main / preload / renderer
  • Cross-layer impact: yes — new cron RPC methods added to GatewayClient (main), preload bridge, and renderer components
  • Invariants touched from docs/architecture-invariants.md: session key format (store-key used for cron session identity)
  • Why those invariants remain protected: cron jobs use buildSessionKey() — the same function normal tasks use — ensuring consistent session identity

Validation

  • pnpm lint
  • pnpm test
  • Manual smoke test
pnpm check (lint + architecture + format + typecheck + test) passes.
Manually tested: create/edit/delete/toggle/run cron jobs, verify task list sync,
filter tabs, search, run history, preset cron expressions, interval unit selector.

Screenshots or recordings

Schedule presets with human-readable cron description, interval unit selector (minutes/hours/days), inline run history below job cards.

Release note

  • User-facing change. Release note is included below.
Add Scheduled Tasks panel for managing recurring agent tasks with cron expressions, interval scheduling, one-shot timers, run history, and task list integration.

Checklist

  • The PR title uses at least one approved prefix: [Feat]
  • The summary explains both what changed and why
  • Validation reflects the commands actually run for this PR
  • Architecture impact is described and references any touched invariants
  • Cross-layer changes are explicitly justified
  • The release note block is accurate

…resets

Full cron management panel: create/edit/delete/toggle/run jobs, view run
history inline, preset cron expressions with human-readable preview,
interval unit selector, and proper ClawWork task-session identity so
cron-created conversations appear in the task list.
@github-actions
Copy link
Copy Markdown
Contributor

Hi @samzong,
Thanks for your pull request!
If the PR is ready, use the /auto-cc command to assign Reviewer to Review.
We will review it shortly.

Details

Instructions for interacting with me using comments are available here.
If you have questions or suggestions related to my behavior, please file an issue against the gh-ci-bot repository.

@samzong samzong merged commit 97c01c8 into main Mar 24, 2026
6 checks passed
@samzong samzong deleted the feat/cron-tasks-ui branch March 25, 2026 02:05
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.

1 participant