package com.ecep.contract.service;

import java.util.List;

import org.springframework.data.domain.Pageable;
import org.springframework.stereotype.Service;

import com.ecep.contract.util.ParamUtils;
import com.ecep.contract.vm.ProjectQuotationViewModel;
import com.ecep.contract.vo.ProjectQuotationVo;
import com.ecep.contract.vo.ProjectVo;

@Service
public class ProjectQuotationService extends QueryService<ProjectQuotationVo, ProjectQuotationViewModel> {

    public List<ProjectQuotationVo> findAllByProject(ProjectVo project) {
        return findAll(ParamUtils.builder().equals("project", project.getId()).build(), Pageable.unpaged()).getContent();
    }

}
