forked from ebhomengo/niki
1
0
Fork 0
niki/service/kind_box_req/service.go

22 lines
552 B
Go

package kindboxservice
import "git.gocasts.ir/ebhomengo/niki/entity"
type Repository interface {
AddKindBoxReq(kindBoxReq entity.KindBoxReq) (entity.KindBoxReq, error)
EditKindBoxReq(kindBoxReqID uint, kindBoxReqInput entity.KindBoxReq) (entity.KindBoxReq, error)
DeleteKindBoxReq(kindBoxReqID uint) error
GetAllKindBoxReq() ([]entity.KindBoxReq, error)
GetKindBoxReqByID(kindBoxReq uint) (entity.KindBoxReq, error)
}
type Service struct {
repo Repository
}
func New(repository Repository) Service {
return Service{
repo: repository,
}
}