package cn.estsh.i3plus.ext.mes.pcn.api.busi.recyclablepackage;

import cn.estsh.i3plus.ext.mes.pcn.pojo.model.MesRecyclablePackageBindingModel;
import cn.estsh.i3plus.pojo.mes.bean.recyclablepackage.MesRecyclablePackageBinding;
import cn.estsh.i3plus.pojo.mes.bean.recyclablepackage.MesRecyclablePackageBindingDetail;
import cn.estsh.impp.framework.boot.util.ResultBean;
import io.swagger.annotations.ApiOperation;

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

/**
 * @Description : 料箱绑定
 * @Reference :
 * @Author : junsheng.li
 * @CreateDate 2024/9/7 10:27
 * @Modify:
 **/
public interface IMesRecyclablePackageBindingService {

    @ApiOperation("查询回收包装绑定明细")
    List<MesRecyclablePackageBindingDetail> findMesRecyclablePackageBindingDetailByPid(String organizeCode, long pid);

    @ApiOperation("查询回收包装绑定明细Map")
    Map<Long,List<MesRecyclablePackageBindingDetail>> findMesRecyclablePackageBindingDetailByPidMap(String organizeCode, List<Long> pidList);

    @ApiOperation("查询回收包装绑定明细数量")
    int findMesRecyclablePackageBindingDetailByPidCount(String organizeCode, long pid);

    @ApiOperation("查询回收包装绑定明细")
    List<MesRecyclablePackageBindingDetail> findMesRecyclablePackageBindingDetailByProductSn(String organizeCode, String productSn);

    @ApiOperation("查询回收包装绑定")
    MesRecyclablePackageBinding getMesRecyclablePackageBindingByPackageSn(String organizeCode, String packageSn);

    @ApiOperation("查询回收包装绑定Map")
    Map<String,List<MesRecyclablePackageBinding>> findMesRecyclablePackageBindingByPackageSnMap(String organizeCode, List<String> packageSnList);

    @ApiOperation("查询回收包装绑定明细")
    List<MesRecyclablePackageBindingDetail> findMesRecyclablePackageBindingDetail(MesRecyclablePackageBindingModel mesRecyclablePackageBindingModel);

    @ApiOperation("扫描信息")
    ResultBean doScan(MesRecyclablePackageBindingModel mesRecyclablePackageBindingModel);

    @ApiOperation("解绑")
    void doMesRecyclablePackageUnBinding(MesRecyclablePackageBinding mesRecyclablePackageBinding, List<MesRecyclablePackageBindingDetail> bindingDetailList,String userName);

}
