20 lines
415 B
Go
20 lines
415 B
Go
package staffrepository
|
|
|
|
import (
|
|
"github.com/ardeman/project-legalgo-go/database"
|
|
authdomain "github.com/ardeman/project-legalgo-go/internal/domain/auth"
|
|
)
|
|
|
|
type StaffRepository struct {
|
|
DB *database.DB
|
|
}
|
|
|
|
type StaffIntf interface {
|
|
GetStaffByEmail(string) (*authdomain.Staff, error)
|
|
Create(*authdomain.Staff) (*authdomain.Staff, error)
|
|
}
|
|
|
|
func New(db *database.DB) StaffIntf {
|
|
return &StaffRepository{db}
|
|
}
|