package cn.estsh.i3plus.ext.mes.api.base.bu;

import cn.estsh.i3plus.ext.mes.pojo.model.bu.BuNumberRuleModel;
import cn.estsh.i3plus.ext.mes.pojo.model.bu.BuWorkCenterModel;
import cn.estsh.i3plus.ext.mes.pojo.model.bu.BuWorkOrderModel;
import cn.estsh.i3plus.ext.mes.pojo.model.bu.MesShiftExtModel;
import cn.estsh.i3plus.pojo.base.bean.ListPager;
import cn.estsh.i3plus.pojo.base.common.Pager;

import java.util.List;

/**
 * @PROJECT_NAME: i3plus-mes-panasonic-bu
 * @DESCRIPTION:
 * @USER: xinwang.yi
 * @DATE: 2022-06-10 13:46
 */

public interface ISxBuBaseDataService {
    /**
     * 分页查询产线
     * @param organizeCode
     * @param workCenterCode
     * @param workCenterName
     * @param pager
     * @return
     */
    ListPager<BuWorkCenterModel> queryWorkCenterByListPager(String organizeCode, String workCenterCode, String workCenterName, String careerCode, String categoryCode, Pager pager);

    /**
     * 按产线类别查询
     * @param organizeCode
     * @param lineType
     * @return
     */
    List<BuWorkCenterModel> queryWorkCenters(String organizeCode, String lineType);

    /**
     * 根据计划时间区间查询工单
     * @param organizeCode
     * @param startTime
     * @param endTime
     * @return
     */
    List<BuWorkOrderModel> queryWorkOrdersByPlanTime(String organizeCode, String startTime, String endTime, List<String> workOrderNoList);

    /**
     * 根据计划时间区间查询工单
     * @param organizeCode
     * @param startTime
     * @param endTime
     * @return
     */
    MesShiftExtModel queryMesShift(String organizeCode, String startTime, String endTime);

    /**
     * 查询条码规则
     * @param organizeCode 组织代码
     * @param partNo 物料编码
     * @param codeType 编码类型
     * @param matchType 匹配类型
     * @return
     */
    BuNumberRuleModel queryMesSnRule(String organizeCode, String partNo, Integer codeType, Integer matchType);

}
