MCPcopy Create free account
hub / github.com/astercloud/aster / UpdateWorkflowStep

Method UpdateWorkflowStep

pkg/memory/project/file_store.go:103–120  ·  view source on GitHub ↗

UpdateWorkflowStep 更新工作流步骤状态

(ctx context.Context, projectID string, step *WorkflowStep)

Source from the content-addressed store, hash-verified

101
102// UpdateWorkflowStep 更新工作流步骤状态
103func (s *FileStore) UpdateWorkflowStep(ctx context.Context, projectID string, step *WorkflowStep) error {
104 memory, err := s.Load(ctx, projectID)
105 if err != nil {
106 return err
107 }
108
109 // 添加工作流更新条目
110 entry := &Entry{
111 ID: fmt.Sprintf("workflow-%s-%d", step.ID, time.Now().Unix()),
112 Category: "workflow",
113 Content: fmt.Sprintf("[%s] %s: %s", step.ID, step.Status, step.Note),
114 Value: step,
115 Source: "system",
116 }
117 memory.AddEntry(SectionWorkflow, entry)
118
119 return s.Save(ctx, memory)
120}
121
122// RecordParams 记录生成参数
123func (s *FileStore) RecordParams(ctx context.Context, projectID string, params *GenerationParams) error {

Callers

nothing calls this directly

Calls 3

LoadMethod · 0.95
SaveMethod · 0.95
AddEntryMethod · 0.80

Tested by

no test coverage detected