package agentkindboxservice

import (
	"context"

	"git.gocasts.ir/ebhomengo/niki/entity"
	params "git.gocasts.ir/ebhomengo/niki/param"
	validator "git.gocasts.ir/ebhomengo/niki/validator/agent/kind_box"
)

type Repository interface {
	GetAwaitingReturnByAgent(ctx context.Context, kindBoxID uint, agentID uint) (entity.KindBox, error)
	GetAllKindBox(ctx context.Context, filter params.FilterRequest, pagination params.PaginationRequest, sort params.SortRequest, searchParams *params.QuerySearch) ([]entity.KindBox, uint, error)
	ReturnKindBox(ctx context.Context, kindBoxID uint, serialNumber string) error
	AddBatchKindBox(ctx context.Context, kindBoxes []entity.KindBox) error
}

type Service struct {
	repo Repository
	vld  validator.Validator
}

func New(repo Repository, vld validator.Validator) Service {
	return Service{
		repo: repo,
		vld:  vld,
	}
}
