mirror of
https://github.com/krau/SaveAny-Bot.git
synced 2026-05-29 20:19:57 +08:00
feat: add task command to client and Title method to Task for tasks queue managing, #157
This commit is contained in:
@@ -125,6 +125,7 @@ func (tq *TaskQueue[T]) RunningTasks() []TaskInfo {
|
||||
}
|
||||
tasks = append(tasks, TaskInfo{
|
||||
ID: task.ID,
|
||||
Title: task.Title,
|
||||
Created: task.created,
|
||||
Cancelled: task.Cancelled(),
|
||||
})
|
||||
@@ -144,6 +145,7 @@ func (tq *TaskQueue[T]) QueuedTasks() []TaskInfo {
|
||||
if !task.Cancelled() {
|
||||
tasks = append(tasks, TaskInfo{
|
||||
ID: task.ID,
|
||||
Title: task.Title,
|
||||
Created: task.created,
|
||||
Cancelled: task.Cancelled(),
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user