package com.qmth.sop.business.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.qmth.sop.business.bean.result.SysMessageCountResult;
import com.qmth.sop.business.bean.result.SysMessageResult;
import com.qmth.sop.business.bean.result.SysMessageWorkResult;
import com.qmth.sop.business.entity.SysMessage;
import org.apache.ibatis.annotations.Param;

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

/**
 * 系统消息 Mapper 接口.
 * 
 * @author: shudonghui
 * @date: 2023-08-07 13:53:28
 * @version: 1.0
 * @email: shudonghui@qmth.com.cn
 * @Company: www.qmth.com.cn
 */
public interface SysMessageMapper extends BaseMapper<SysMessage> {

	/**
	 * 查询列表
	 * @param iPage
	 * @return
	 */
	public IPage<SysMessageResult> query(IPage<Map> iPage, @Param("noticeId")  Long noticeId, @Param("city")  String city, @Param("supplierId")  Long supplierId, @Param("status")  Boolean status);
	/**
	 * 查询列表
	 * @return
	 */
	public List<SysMessageResult> query(@Param("noticeId")  Long noticeId, @Param("city")  String city, @Param("supplierId")  Long supplierId, @Param("status")  Boolean status);

	SysMessageCountResult count(@Param("noticeId") long noticeId);

	long countByTypes(@Param("typeStr") String[] typeStr,@Param("userId") Long userId);

	IPage<SysMessageWorkResult> pageByTypes(IPage<Map> iPage,@Param("typeStr")  String[] typeStr,@Param("status")  Boolean status,@Param("serviceId")  Long serviceId,@Param("custom")  String custom,@Param("query")  String query,@Param("startTime")  Long startTime,@Param("endTime")  Long endTime,@Param("userId") Long userId);
}