package com.jwipc.order.convert;

import com.jwipc.order.dto.ShortagePlanImportDTO;
import com.jwipc.order.dto.ShortagePlanReleaseDTO;
import com.jwipc.order.entity.ShortageData;
import com.jwipc.order.entity.ShortageDetail;
import com.jwipc.order.model.po.ShortagePlanReleasePO;
import org.mapstruct.Mapper;
import org.mapstruct.MappingTarget;

import java.util.List;


@Mapper(componentModel = "spring")
public interface ShortageDetailConvert {
    List<ShortageDetail> importDtos2Entities(List<ShortagePlanImportDTO> cachedDataList);

    ShortageData fillData(@MappingTarget ShortageData shortageData, ShortageDetail entity);

    List<ShortagePlanReleaseDTO> pos2Dtos(List<ShortagePlanReleasePO> list);

    List<ShortagePlanImportDTO> entities2Dtos(List<ShortageDetail> shortageDetails);
}
