package kindboxreqservice import ( "context" param "git.gocasts.ir/ebhomengo/niki/param/kind_box_req" richerror "git.gocasts.ir/ebhomengo/niki/pkg/rich_error" ) func (s Service) GetByID(ctx context.Context, req param.KindBoxReqGetByIDRequest) (param.KindBoxReqGetByIDResponse, error) { const op = "kindboxreqservice.GetByID" kindBoxReq, err := s.repo.GetKindBoxReqByID(ctx, req.KindBoxReqID) if err != nil { return param.KindBoxReqGetByIDResponse{}, richerror.New(op).WithErr(err).WithKind(richerror.KindUnexpected) } return param.KindBoxReqGetByIDResponse{KindBoxReq: kindBoxReq}, nil }