Added swagger docs comment
continuous-integration/drone/pr Build was killed Details

This commit is contained in:
kolaente 2019-11-02 20:57:21 +01:00
parent 8a6b176484
commit 70eb67a2f1
Signed by: konrad
GPG Key ID: F40E70337AB24C9B
1 changed files with 12 additions and 0 deletions

View File

@ -831,6 +831,18 @@ func (t *Task) Delete() (err error) {
return
}
// ReadOne gets one task by its ID
// @Summary Get task one task by its ID
// @Description Returns one task by its ID
// @tags task
// @Accept json
// @Produce json
// @Param ID path int true "The task ID"
// @Security JWTKeyAuth
// @Success 200 {object} models.Task "The task"
// @Failure 404 {object} models.Message "Task not found"
// @Failure 500 {object} models.Message "Internal error"
// @Router /tasks/all [get]
func (t *Task) ReadOne() (err error) {
taskMap := make(map[int64]*Task, 1)