package com.ho.business.mapper;

import com.ho.business.entity.PlanningCurve;
import com.ho.business.entity.PlanningCurveTemplate;
import org.apache.ibatis.annotations.Param;

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

public interface PlanningCurveMapper {

    /**
     * 查询模板列表接口
     *
     * @param template
     * @return
     */
    public List<Map<String,Object>> getPlanningCurveTemplates(PlanningCurveTemplate template);

    public int getSeq();

    /**
     * 新增模板
     *
     * @param template
     * @return
     */
    public int addPlanningCurveTemplate(PlanningCurveTemplate template);

    /**
     * 新增曲线
     *
     * @param curves
     * @return
     */
    public int addPlanningCurve(@Param("curves") List<PlanningCurve> curves, @Param("planningTemplateId") Integer planningTemplateId);

    /**
     * 编辑计划曲线模板
     *
     * @param template
     * @return
     */
    public int modifyPlanningCurveTemplate(PlanningCurveTemplate template);

    /**
     * 删除计划曲线数据
     *
     * @param id
     * @return
     */
    public int deleteCurves(@Param("id") Integer id);

    /**
     * 根据计划曲线模板id删除
     *
     * @param ids
     * @return
     */
    public int deletePlanningCurveTemplates(@Param("ids") List<Integer> ids);

    public int batchDeleteCurves(@Param("ids") List<Integer> ids);

    public int checkNo(@Param("templateNo")String templateNo,@Param("stationId")Integer stationId,@Param("temId")Integer temId);

    public int checkName(@Param("templateName")String templateName,@Param("stationId")Integer stationId,@Param("temId")Integer temId);

    public List<PlanningCurveTemplate> getPlanningCurveTemplate(PlanningCurveTemplate template);



}
