timerecordapp

package
v0.0.0-...-1920916 Latest Latest
Warning

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

Go to latest
Published: Apr 22, 2023 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type App

type App struct {
	// contains filtered or unexported fields
}

func New

func New(repo TimeRecordRepo) *App

func (*App) AddTimeRecord

func (a *App) AddTimeRecord(c *gin.Context, record domain.TimeRecord) (uint64, error)

func (*App) GetLastByEmpoyeeID

func (a *App) GetLastByEmpoyeeID(c *gin.Context, id uint64) (domain.TimeRecord, error)

func (*App) ListTimeRecords

func (a *App) ListTimeRecords(c *gin.Context) ([]domain.TimeRecord, error)

type TimeRecordRepo

type TimeRecordRepo interface {
	Save(ctx context.Context, t domain.TimeRecord) (uint64, error)
	GetLastByEmpoyeeID(ctx context.Context, id uint64) (domain.TimeRecord, error)
	List(ctx context.Context) ([]domain.TimeRecord, error)
}

Jump to

Keyboard shortcuts

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