feat(webui): let the operator choose the retry worktree mode
A retry now carries the operator's worktree choice (refresh onto the base branch or continue the work already pushed on the task branch) from the dashboard through the task action to the daemon dispatch, and persists it on the task row so it survives a reload. The daemon resolves the mode from the task, never from the workflow; BeginRemediation records continue explicitly so a remediation still resumes its pull request branch.
This commit is contained in:
1 parent
ef203ce30a
commit
19520a63e5
58 files changed
+977
-252
No files matched your search
@@ -21,23 +21,26 @@ type changeStatusMeta struct {
|
||||
// struct rather than an inline map so the wire shape is declared in one place
|
||||
// and pinned against the dashboard's freeze-dried snapshot by a fixture test.
|
||||
type taskMetaView struct {
|
||||
Statuses []taskstate.StatusMeta `json:"statuses"`
|
||||
Actions []taskstate.ActionMeta `json:"actions"`
|
||||
ChangeStatuses []changeStatusMeta `json:"change_statuses"`
|
||||
ConfigSchema string `json:"config_schema"`
|
||||
Statuses []taskstate.StatusMeta `json:"statuses"`
|
||||
Actions []taskstate.ActionMeta `json:"actions"`
|
||||
RetryModes []taskstate.RetryModeMeta `json:"retry_modes"`
|
||||
ChangeStatuses []changeStatusMeta `json:"change_statuses"`
|
||||
ConfigSchema string `json:"config_schema"`
|
||||
}
|
||||
|
||||
// buildTaskMeta derives the lifecycle presentation catalog: the status
|
||||
// vocabulary (with label, pill severity, "needs you" grouping), the operator
|
||||
// action controls (with label, button variant, confirm prompt), the
|
||||
// action controls (with label, button variant, confirm prompt), the retry
|
||||
// worktree modes (with label, description and which is the default), the
|
||||
// changes_captured status labels and the schema stamp a config_captured
|
||||
// payload carries. Everything the dashboard can present that also exists on
|
||||
// the server is derived here, so the frontend never has to keep a hand-synced
|
||||
// copy of the vocabulary or the control set.
|
||||
func buildTaskMeta() taskMetaView {
|
||||
return taskMetaView{
|
||||
Statuses: taskstate.Statuses(),
|
||||
Actions: taskstate.ActionCatalog(),
|
||||
Statuses: taskstate.Statuses(),
|
||||
Actions: taskstate.ActionCatalog(),
|
||||
RetryModes: taskstate.RetryModes(),
|
||||
ChangeStatuses: []changeStatusMeta{
|
||||
{ID: task.ChangeAdded, Label: "Added"},
|
||||
{ID: task.ChangeModified, Label: "Modified"},
|
||||
|
||||
Reference in new issue
Block a user