repository

package
v0.0.0-...-9a826e6 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 5, 2023 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DashboardRepository

type DashboardRepository interface {
	CreateDashboard(dashboard models.Dashboard) (models.Dashboard, error)
	DeleteDashboard(id uuid.UUID) (models.Dashboard, error)
	ListDashboardsByUser(userID string) ([]models.Dashboard, error)
}

func NewDashboardRepository

func NewDashboardRepository(db *gorm.DB) DashboardRepository

type ProjectRepository

type ProjectRepository interface {
	CreateProject(project models.Project) (models.Project, error)
	UpdateProject(project models.Project) (models.Project, error)
	ListProjectsByUser(userID string) ([]models.Project, error)
	GetProjectByID(projectID string) (models.Project, error)
	DeleteProject(projectID string) error
	ListProjectMembers(projectID string) ([]models.User, error)
	AddProjectMember(userID string, prjID uint) error
	RemoveProjectMember(userID string, prjID uint) error
}

func NewProjectRepository

func NewProjectRepository(db *gorm.DB) ProjectRepository

type TaskRepository

type TaskRepository interface {
	CreateTask(task models.Task) (models.Task, error)
	GetTaskByID(taskID string) (models.Task, error)
	UpdateTask(task models.Task) (models.Task, error)
	DeleteTask(taskID string) error
	ListTasksByUser(userID string) ([]models.Task, error)
	ListTasksByProject(projectID string) ([]models.Task, error)
}

func NewTaskRepository

func NewTaskRepository(db *gorm.DB) TaskRepository

type UserRepository

type UserRepository interface {
	CreateUser(user models.User) (models.User, error)
	GetUserByEmail(email string) (models.User, error)
	GetUserByID(id string) (models.User, error)
}

func NewUserRepository

func NewUserRepository(db *gorm.DB) UserRepository

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL