aides-repo-api/internal/controllers/taskcontroller/controller.go

22 lines
468 B
Go
Raw Normal View History

2024-12-12 13:27:07 +00:00
package taskcontroller
import (
"code.aides.space/aides-infra/aides-repo-api/internal/models"
"code.aides.space/aides-infra/aides-repo-api/internal/services/taskservice"
2024-12-12 13:27:07 +00:00
)
2024-12-26 18:16:05 +00:00
type TaskService interface {
Create(repo string) (*models.Task, error)
Upload(input *taskservice.TaskUploadInput) error
}
2024-12-12 13:27:07 +00:00
type TaskController struct {
2024-12-26 18:16:05 +00:00
taskService TaskService
2024-12-12 13:27:07 +00:00
}
2024-12-26 18:16:05 +00:00
func New(taskService TaskService) *TaskController {
2024-12-12 13:27:07 +00:00
return &TaskController{
taskService: taskService,
}
}