mirror of
https://github.com/tiennm99/goclaw.git
synced 2026-10-14 10:18:42 +00:00
fix(teams): show task_number in create result and allow search to satisfy gate
This commit is contained in:
1 parent
de2eca9acb
commit
6106d3d04f
2 files changed
+3
-3
No files matched your search
@@ -185,7 +185,7 @@ func (t *TeamTasksTool) executeCreate(ctx context.Context, args map[string]any)
|
||||
if err := t.manager.teamStore.AssignTask(ctx, task.ID, assigneeID, team.ID); err != nil {
|
||||
slog.Warn("executeCreate: fallback assign failed", "task_id", task.ID, "error", err)
|
||||
} else {
|
||||
t.manager.broadcastTeamEvent(protocol.EventTeamTaskAssigned, protocol.TeamTaskEventPayload{
|
||||
t.manager.broadcastTeamEvent(protocol.EventTeamTaskDispatched, protocol.TeamTaskEventPayload{
|
||||
TeamID: team.ID.String(),
|
||||
TaskID: task.ID.String(),
|
||||
TaskNumber: task.TaskNumber,
|
||||
@@ -203,7 +203,7 @@ func (t *TeamTasksTool) executeCreate(ctx context.Context, args map[string]any)
|
||||
}
|
||||
}
|
||||
|
||||
return NewResult(fmt.Sprintf("Task created: %s (id=%s, identifier=%s, status=%s)", subject, task.ID, task.Identifier, status))
|
||||
return NewResult(fmt.Sprintf("Task created: %s (id=%s, task_number=%d, status=%s)", subject, task.ID, task.TaskNumber, status))
|
||||
}
|
||||
|
||||
func (t *TeamTasksTool) executeComment(ctx context.Context, args map[string]any) *Result {
|
||||
|
||||
@@ -169,7 +169,7 @@ func (t *TeamTasksTool) executeList(ctx context.Context, args map[string]any) *R
|
||||
ptd.MarkListed()
|
||||
}
|
||||
|
||||
tasks, err := t.manager.teamStore.ListTasks(ctx, team.ID, "priority", statusFilter, filterUserID, "", listChatID, offset)
|
||||
tasks, err := t.manager.teamStore.ListTasks(ctx, team.ID, "priority", statusFilter, filterUserID, "", listChatID, 0, offset)
|
||||
if err != nil {
|
||||
return ErrorResult("failed to list tasks: " + err.Error())
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user