package com.zcloud.safetyDutyList.persistence.mapper.tasklist;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.zcloud.safetyDutyList.persistence.dataobject.tasklist.FeedbackDO;
import org.apache.ibatis.annotations.Mapper;

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

/**
 * 反馈Mapper接口
 * <p>
 * 基于MyBatis-Plus的BaseMapper，定义反馈数据的SQL映射操作，
 * 包括分页查询、按清单ID和任务详情ID查询、按反馈业务ID查询等方法。
 */
@Mapper
public interface FeedbackMapper extends BaseMapper<FeedbackDO> {
    IPage<FeedbackDO> feedbackPage(IPage<FeedbackDO> iPage, Map<String, Object> params);

    List<FeedbackDO> listByTaskListId(String taskListId);

    List<FeedbackDO> listByTaskDetailId(String taskDetailId);

    List<FeedbackDO> listByTaskExecutionId(String taskExecutionId);

    List<FeedbackDO> listByTaskIssueId(String taskIssueId);

    List<FeedbackDO> listByTaskExecutionIdAndPeriodFlag(String taskExecutionId, String feedbackPeriodFlag);

    FeedbackDO getByFeedbackId(String feedbackId);
}
