package com.sw.mes.yb.pad.service;

import java.math.BigDecimal;
import java.util.List;
import java.util.Map;

import com.sw.mes.base.factory.inspect.entity.PaintingLine;
import com.sw.mes.core.base.BaseService;
import com.sw.mes.core.response.Result;
import com.sw.mes.yb.pad.dto.*;
import com.sw.mes.yb.pad.entity.ProductionPaintingLine;
import com.sw.mes.yb.production.entity.LongCrystal;
import io.swagger.annotations.ApiParam;
import org.springframework.web.bind.annotation.RequestBody;

import javax.validation.Valid;

/**
 * @Author
 * @Description：
 * @Date:
 * @Modified By:
 */
public interface ProductionPaintingLineService extends BaseService<ProductionPaintingLine> {


//    根据单晶编号获取画线明细等规则
//    Result GetCrystalInfo(String crystalNo);
//
//
//    // 获取画线规则
//    Result getLineRule(String crystalNo);
//
//
//    // 获取样片规则
//    Result getPieceRule(String crystalNo);
//

    // 获取定向画线接口
    Result getDirectional();

    Result findLineInfo(String crystalNo);

    Result<LineDetailedResultDto> getLineInfo(LineParamDto lineParamDto);

    /**
     * 创建划线信息
     * @param productionPaintingLineDto
     * @param longCrystal
     * @param weightLossCoefficient
     */
    Result<String> createAll(LineDetailedParamDto productionPaintingLineDto, LongCrystal longCrystal, BigDecimal weightLossCoefficient, LineParamDataDto lineParamDto);

    void getCrystalNoInfos(LineDetailedParamDto lineDetailedParamDto, LongCrystal longCrystal);

    /**
     * 美科项目重写画线生成编码
     * @param drawLineDto
     * @param longCrystal
     */
     void getDrawlinginfos(DrawLineDto drawLineDto, LongCrystal longCrystal);

     void getDrawlinginfosNew(DrawLineDto drawLineDto);
    //
//
//    // 打印画线信息
//    Result printLineInfo(String crystalNo);
//
//
//    // 删除画线记录时 删除掉对应所有晶段样片信息
    void deleteInfo(Long id);

    ProductionPaintingLine findByCrystalNo(String crystalNo);

    /**
     * 匹配圆棒画线
     *
     * @param drawLineParamDto
     * @return
     */
    Result<DrawLineDto> matchDrawLine(DrawLineParamDto drawLineParamDto);


    List<PaintingLine> getDrawLineRuleList(String crystalNo);

    void sendWjbzToMcs(String vehicleCode);
    void sendWjbzToMcsForDeletePaintngLine(String vehicleCode);

    /**
     * 匹配圆棒划线
     *
     * @param drawLineParamDto
     * @return
     */
    Result<DrawLineDto> matchDrawLineNew(DrawLineParamDto drawLineParamDto);


    /**
     * 获取产能录入信息
     *
     * @return
     */
    List<Map<String, Object>> capacityInputData();

    void newReportSapLongCrystalHours(LongCrystal longCrystal);

    Result<String> create(DrawLineDto drawLineDto);
}