22 lines
448 B
Go
Raw Normal View History

package staffrepository
import (
"legalgo-BE-go/database"
authdomain "legalgo-BE-go/internal/domain/auth"
)
type StaffRepository struct {
DB *database.DB
}
2025-02-24 16:48:20 +08:00
type StaffIntf interface {
2025-02-24 19:47:40 +08:00
GetStaffByEmail(string) (*authdomain.Staff, error)
2025-02-27 18:59:58 +08:00
GetStaffByID(string) (*authdomain.Staff, error)
2025-02-24 16:48:20 +08:00
Create(*authdomain.Staff) (*authdomain.Staff, error)
2025-02-27 18:59:58 +08:00
Update(authdomain.Staff) error
}
2025-02-24 16:48:20 +08:00
func New(db *database.DB) StaffIntf {
return &StaffRepository{db}
}