21 lines
386 B
Go
Raw Normal View History

2025-02-24 16:48:20 +08:00
package subscriberepository
import (
"legalgo-BE-go/database"
subscribedomain "legalgo-BE-go/internal/domain/subscribe"
)
2025-02-24 16:48:20 +08:00
type accessor struct {
db *database.DB
2025-02-24 16:48:20 +08:00
}
type Subscribe interface {
2025-02-24 16:48:20 +08:00
Create(string) (string, error)
GetByID(string) (subscribedomain.Subscribe, error)
Update(subscribedomain.Subscribe) error
2025-02-24 16:48:20 +08:00
}
func New(db *database.DB) Subscribe {
return &accessor{db}
2025-02-24 16:48:20 +08:00
}