package com.kamco.cd.kamcoback.postgres.core;

import com.kamco.cd.kamcoback.model.dto.ModelMngDto;
import com.kamco.cd.kamcoback.postgres.repository.model.ModelMngRepository;
import java.time.LocalDate;
import lombok.RequiredArgsConstructor;
import org.springframework.data.domain.Page;
import org.springframework.stereotype.Service;

@Service
@RequiredArgsConstructor
public class ModelMngCoreService {

  private final ModelMngRepository modelMngRepository;

  public Page<ModelMngDto.ModelList> findModelMgmtList(
      ModelMngDto.searchReq searchReq,
      LocalDate startDate,
      LocalDate endDate,
      String modelType,
      String searchVal) {
    return modelMngRepository.findModelMgmtList(
        searchReq, startDate, endDate, modelType, searchVal);
  }
}
