fix
This commit is contained in:
@@ -160,11 +160,14 @@ func (s *Server) handleV1StartProcess(w http.ResponseWriter, r *http.Request) {
|
||||
}
|
||||
|
||||
primary := jobs[0]
|
||||
// processed_items is the completed count — stay 0 until the worker finishes.
|
||||
// total_items is the enqueue size; status stays pending/processing until poll COMPLETED.
|
||||
resp := map[string]any{
|
||||
"process_id": primary.ID.String(),
|
||||
"status": "pending",
|
||||
"message": fmt.Sprintf("Processing started for %d product(s)", len(rawIDs)),
|
||||
"total_items": totalItems,
|
||||
"processed_items": len(rawIDs),
|
||||
"processed_items": 0,
|
||||
}
|
||||
if len(jobs) > 1 {
|
||||
siblings := make([]string, 0, len(jobs)-1)
|
||||
|
||||
Reference in New Issue
Block a user