Database interface extension, GetAllProjects, GetUserRole, GetProjectsForUser

This commit is contained in:
Imbus 2024-03-14 19:48:49 +01:00
parent df7ca1ab90
commit e1153934c6
3 changed files with 98 additions and 9 deletions

View file

@ -1,16 +1,11 @@
package types
import (
"time"
)
// Project is a struct that holds the information about a project
type Project struct {
ID int `json:"id" db:"id"`
Name string `json:"name" db:"name"`
Description string `json:"description" db:"description"`
Owner string `json:"owner" db:"owner"`
Created time.Time `json:"created" db:"created"`
ID int `json:"id" db:"id"`
Name string `json:"name" db:"name"`
Description string `json:"description" db:"description"`
Owner string `json:"owner" db:"owner_user_id"`
}
// As it arrives from the client