package com.cyksj.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.cyksj.model.dto.OriSkuDto;
import com.cyksj.model.entity.GoodsDonSku;
import com.cyksj.model.entity.YhShopGoodsSku;
import com.cyksj.model.views.GoodsDonSkuDetailView;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * @author chan
 * @date 2022/9/26 6:54 PM
 */
public interface GoodsDonSkuMapper  extends BaseMapper<GoodsDonSku> {

	List<Long> selectAIMonthSkuIds(@Param("list") List<Long> goodsIds);

	List<Long> getSpecificSkuIdsByGoodsIds(@Param("list") List<Long> aiGoodsIds, @Param("months") Integer months);

	List<Long> getSpecificSkuIdsByGoodsId(@Param("goodsId") Long goodsId, @Param("num") Integer num, @Param("months") Integer months);

	List<YhShopGoodsSku> selectSkuShops(@Param("list") List<Long> goodsIds);

	List<Long> selectSingleSkuIdsByGoodsId(Long goodsId);

	GoodsDonSku checkAndReturnMinPriceUserOwnsSku(@Param("goodsId") Long goodsId, @Param("dsUserId") Long dsUserId);

	OriSkuDto selectRenewOriSku(Long skuId);

	String selectExchangeTitle(@Param("ids") List<Long> ids);

	List<Long> selectGIdsBySkuIds(@Param("ids") List<Long> ids);

	List<GoodsDonSkuDetailView> selectExchangeTitleSkus(@Param("ids") List<Long> skuIds);

	List<Long> selectIdpGptAndRechargeSkuIds(@Param("gptPlusGid") Long gptPlusGid, @Param("gptRechargeGoodsId") Long gptRechargeGoodsId);
}
