package com.steerinfo.meterwork.meterworkstorageactual.mapper;

import com.steerinfo.framework.mapper.IBaseMapper;
import com.steerinfo.meterwork.dto.StaffPerformanceAnalysis;
import com.steerinfo.meterwork.meterworkstorageactual.model.MeterWorkStorageActual;

import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.Objects;

import feign.Param;
import org.apache.ibatis.annotations.Mapper;

@Mapper
public interface MeterWorkStorageActualMapper extends IBaseMapper<MeterWorkStorageActual, String> {
    List<MeterWorkStorageActual> selectView(Map<String, Object> parmas);

    List<StaffPerformanceAnalysis> analysis(HashMap<String, Object> obj);

    String getNewID(@Param(value="afl")String afl);

    List<MeterWorkStorageActual> doQueryWf(MeterWorkStorageActual obj);

    List<MeterWorkStorageActual> doQueryTimeWf(HashMap<String, Object> obj);

    int isHaveCntWf(MeterWorkStorageActual obj);

    List<MeterWorkStorageActual> doQueryNieWf(HashMap<String, Object> obj);

    String selectMaxPackgeNo(String predictionNo);

    /**
     * 分组查询计算同计量点、同规格、同钢种、同班次单支平均重量
     * @param models
     * @return
     */
    List<MeterWorkStorageActual> selectCheckGroup(List<MeterWorkStorageActual> models);

    /**
     * 查询最大的MES炉号
     * @param heatNo
     * @return
     */
    int selectMaxHeatNoSeq(String heatNo);

    /**
     * 查询热送磅需要同步的数据
     * @return
     */
    List<MeterWorkStorageActual> querySyncDataToMes00031();

    /**
     * 热送磅分组数据查询
     * @param params
     * @return
     */
    List<MeterWorkStorageActual> doQueryGroup(HashMap params);

    /**
     * C#端热送磅审核数据查询
     * @param params
     * @return
     */
    List<MeterWorkStorageActual> doQueryCheckCount(HashMap params);

    /**
     * 查询预报编号已经过了多少只了，然后若超出总支数，则将预报置为已完成
     * @param predictionNo
     * @return
     */
    String selectCountPackgeNo(String predictionNo);
}