package com.storlead.sales.service.sku;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.storlead.framework.common.result.Result;
import com.storlead.sales.pojo.dto.sku.QuotationPriceDTO;
import com.storlead.sales.pojo.vo.sku.QuotationDetailVO;
import com.storlead.sales.pojo.dto.sku.QuotationAddDTO;
import com.storlead.sales.pojo.dto.sku.QuotationListDTO;
import com.storlead.sales.pojo.dto.sku.QuotationSearchDTO;
import com.storlead.sales.pojo.entity.sku.QuotationEntity;
import com.storlead.framework.mybatis.service.MyBaseService;
import com.storlead.sales.pojo.vo.sku.QuotationListVO;

import java.util.List;
import java.util.Map;

/**
 * <p>
 * 报价单表 服务类
 * </p>
 *
 * @author YPZ
 * @since 2024-08-09
 */
public interface QuotationService extends MyBaseService<QuotationEntity> {

    /***
      * @Description: 新增确认报价
      * @Param:
      * @return:
      * @Author: YPZ
      * @Date: 2024/8/9 15:13
      */
    Result<?> addQuotation(QuotationAddDTO quotationAddDTO);

    /***
     * @Description: 编辑确认报价
     * @Param:
     * @return:
     * @Author: YPZ
     * @Date: 2024/8/9 15:13
     */
    Result<?> editQuotation(QuotationAddDTO quotationAddDTO);

    /***
      * @Description: 通过Id查询报价单详情
      * @Param:
      * @return:
      * @Author: YPZ
      * @Date: 2024/8/13 11:50
      */
    QuotationDetailVO getQuotationDetailVOById(Long id);

    QuotationDetailVO getQuotationDetailVO(QuotationSearchDTO quotationSearchDTO);

    /***
      * @Description: 通过客户id查看列表
      * @Param:
      * @return:
      * @Author: YPZ
      * @Date: 2024/8/15 10:21
      */
    Result<IPage<QuotationListVO>> selectListVO(QuotationListDTO quotationListDTO);

    /***
      * @Description: 根据报价id获取报价信息
      * @Param:
      * @return:
      * @Author: YPZ
      * @Date: 2024/8/15 18:32
      */
    Map<Long, QuotationEntity> getQuotationMap(List<Long> quotationIdList);

    Result<?> getPrice(QuotationPriceDTO quotationPriceDTO);

    Result<?> getPriceUSD(QuotationPriceDTO quotationPriceDTO);

    Result<?> getLastQuotation(QuotationSearchDTO quotationSearchDTO);

    void deleteCustomerId();
}
