package com.testor.module.notice.dao;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.testor.module.notice.model.domain.TSysNotice;
import com.testor.module.notice.model.dto.TSysNoticeParam;
import com.tongtech.tfw.backend.common.models.supers.SuperDao;
import org.apache.ibatis.annotations.Param;
import org.mapstruct.Mapper;

import java.util.List;

/**
 * noticeMapper接口
 *
 * @author tong-framework
 * @date 2022-04-27 18:10:12
 */
@Mapper
public interface TSysNoticeDao extends SuperDao<TSysNotice> {
    //获取已读数据
    IPage<TSysNotice> getRead(Page<TSysNotice> resultPage, @Param("param") TSysNoticeParam param, @Param("startTime") String startTime, @Param("endTime") String endTime, @Param("list") List<String> list, @Param("loginUserId") String loginUserId, @Param("orgId") String orgId);

    // 获取未读数据
    IPage<TSysNotice> getUnRead(Page<TSysNotice> resultPage, @Param("param") TSysNoticeParam param,@Param("startTime") String startTime,@Param("endTime") String endTime,@Param("list") List<String> list,@Param("loginUserId") String loginUserId,@Param("orgId")String orgId);

    IPage<TSysNotice> getNewsAndNotice(Page<TSysNotice> resultPage,@Param("param") TSysNoticeParam param ,@Param("orgId") String orgId);
}
