package com.jwipc.sys.service.impl;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.jwipc.sys.entity.EmailLog;
import com.jwipc.sys.mapper.EmailLogMapper;
import com.jwipc.sys.model.po.EmailLogPO;
import com.jwipc.sys.model.query.EmailLogQuery;
import com.jwipc.sys.service.IEmailLogService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * <p>
 * 系统邮件日志 服务实现类
 * </p>
 *
 * @author shenyang.ou
 * @since 2024-01-29
 */
@Service
public class EmailLogServiceImpl extends ServiceImpl<EmailLogMapper, EmailLog> implements IEmailLogService {

    @Override
    public List<EmailLogPO> findPageByQuery(Page<EmailLog> dbPage, EmailLogQuery query) {
        if (dbPage==null){
            return baseMapper.findPageByQuery(query);
        }
        return baseMapper.findPageByQuery(dbPage,query);
    }
}
