/*
* Copyright (c) 京北方信息技术股份有限公司 Corporation 2022 . All rights reserved.
*
*/
package net.northking.cctp.executePlan.db.service;

import net.northking.cctp.common.db.BasicService;
import net.northking.cctp.executePlan.db.entity.AtuPlanBatch;
import net.northking.cctp.executePlan.dto.planBatch.AtuPlanBatchDetailDto;

import java.time.LocalDateTime;
import java.util.List;

/**
 * 计划执行批次表
 *
 * <p>文件内容由代码生成器产生，请不要手动修改！ <br>
 * createdate:  2022-12-07 17:41:08  <br>
 * @author:  maven-cctp-plugin  <br>
 * @since:  1.0 <br>
 */
public interface AtuPlanBatchService extends BasicService<AtuPlanBatch>
{
    /**
     * 查询计划最大批次号计划
     * @return 结果集
     */
    List<AtuPlanBatch> queryPlanMaxBatchNumList(String endTime, int fromIndex, int toIndex);


    Integer updateByEntity(AtuPlanBatch entity);

    /**
     * 根据id查询批次详情
     * @param batchId id
     * @return 详情
     */
    AtuPlanBatchDetailDto queryBatchDetailById(String batchId);

    /**
     * 统计计划批次总数-去重
     * @param endTime 结束时间
     * @return 结果
     */
    int countPlanMaxBatch(String endTime);

    List<AtuPlanBatch> queryNeedClearBatch(LocalDateTime localDateTime);

    /**
     * 更新批次表附件清除字段
     * @param batchIds 批次Ids
     */
    void updateAttachmentClearStatusByIds(List<String> batchIds);

}
