package agentkindboxreqservice import ( "context" param "git.gocasts.ir/ebhomengo/niki/param/agent/kind_box" "git.gocasts.ir/ebhomengo/niki/entity" params "git.gocasts.ir/ebhomengo/niki/param" validator "git.gocasts.ir/ebhomengo/niki/validator/agent/kind_box_req" ) type Repository interface { GetAllKindBoxReq(ctx context.Context, filter params.FilterRequest, pagination params.PaginationRequest, sort params.SortRequest) ([]entity.KindBoxReq, uint, error) DeliverKindBoxReq(ctx context.Context, kindBoxReqID uint) error GetAwaitingDeliveryByAgent(ctx context.Context, kindBoxReqID uint, agentID uint) (entity.KindBoxReq, error) GetByID(ctx context.Context, id uint) (entity.KindBoxReq, error) } type KindBoxSvc interface { AddBatchKindBox(ctx context.Context, req param.AddKindBoxRequest) (param.AddKindBoxResponse, error) } type Service struct { repo Repository kindBoxSvc KindBoxSvc vld validator.Validator } func New(repo Repository, vld validator.Validator, kindBoxSvc KindBoxSvc) Service { return Service{ repo: repo, vld: vld, kindBoxSvc: kindBoxSvc, } }