package com.sw.mes.production.service;

import com.sw.mes.core.base.BaseService;
import com.sw.mes.production.entity.FormulaSchemeDetail;

import java.util.List;

/**
 * @Author
 * @Description：
 * @Date:
 * @Modified By:
 */
public interface FormulaSchemeDetailService extends BaseService<FormulaSchemeDetail> {
    List<FormulaSchemeDetail> findByFormulaSchemeId(Long id);

    List<FormulaSchemeDetail> findByFormulaSchemeIdAndMaterialTypeAndMaterialClassName(Long formulaSchemeId, String materialType, String materialClassName);

    /**
     * 根据投料任务和物料code获取方案详情
     * @param taskId
     * @param againNum
     * @param materialCode
     * @return
     */
    FormulaSchemeDetail findByTaskAndMaterialCode(Long taskId, Integer againNum, String materialCode);
}
