package ink.wgink.module.form.dao.docnolog;

import ink.wgink.exceptions.RemoveException;
import ink.wgink.exceptions.SaveException;
import ink.wgink.exceptions.SearchException;
import ink.wgink.exceptions.UpdateException;
import ink.wgink.interfaces.init.IInitBaseTable;
import ink.wgink.module.form.pojo.dtos.docnolog.DocNoLogDTO;
import ink.wgink.module.form.pojo.pos.docnolog.DocNoLogPO;
import org.springframework.stereotype.Repository;

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

/**
 * @ClassName: IDocNoLogDao
 * @Description: 文号日志
 * @Author: CodeFactory
 * @Date: 2022-06-29 14:19:06
 * @Version: 3.0
 **/
@Repository
public interface IDocNoLogDao extends IInitBaseTable {

    /**
     * 新增文号日志
     *
     * @param params
     * @throws SaveException
     */
    void save(Map<String, Object> params) throws SaveException;

    /**
     * 删除文号日志（物理）
     *
     * @param params
     * @throws RemoveException
     */
    void delete(Map<String, Object> params) throws RemoveException;

    /**
     * 修改文号日志
     *
     * @param params
     * @throws UpdateException
     */
    void update(Map<String, Object> params) throws UpdateException;

    /**
     * 文号日志详情
     *
     * @param params
     * @return
     * @throws SearchException
     */
    DocNoLogDTO get(Map<String, Object> params) throws SearchException;

    /**
     * 文号日志详情
     *
     * @param params
     * @return
     * @throws SearchException
     */
    DocNoLogPO getPO(Map<String, Object> params) throws SearchException;

    /**
     * 文号日志列表
     *
     * @param params
     * @return
     * @throws SearchException
     */
    List<DocNoLogDTO> list(Map<String, Object> params) throws SearchException;

    /**
     * 文号日志列表
     *
     * @param params
     * @return
     * @throws SearchException
     */
    List<DocNoLogPO> listPO(Map<String, Object> params) throws SearchException;

    /**
     * 文号日志统计
     *
     * @param params
     * @return
     * @throws SearchException
     */
    Integer count(Map<String, Object> params) throws SearchException;

    /**
     * 获取最新的文号日志
     *
     * @param params
     * @return
     * @throws SearchException
     */
    DocNoLogPO getLatestPO(Map<String, Object> params) throws SearchException;

}