package com.xhpc.general.mapper;

import com.xhpc.general.domain.HelpEntity;
import org.apache.ibatis.annotations.Param;

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

/**
 * 帮助Mapper接口
 * program: ruoyi
 * User: HongYun
 * Date:2021-08-02 11
 */
public interface XhpcHelpMapper {

    int deleteHelpItem(@Param("helpId") Long helpId);
    /**
     * Counting the quantity by the type,title.
     * @param type
     * @return
     */
    int countSameTypeTitle(@Param("type") Integer type,@Param("title") String title);


    int insertHelpItem(@Param("title") String title,@Param("content") String content,@Param("type") Integer type);

    int updateHelpItem(@Param("helpId") Long helpId,@Param("title") String title,@Param("type")Integer type,@Param("content") String content);

    List<HelpEntity> selectHelpItems(@Param("title") String title, @Param("createBy") String createBy, @Param("type") Integer type);

    HelpEntity selectHelpItem(@Param("helpId") Long helpId);

    List<Map<String,Object>> selectTitleId(@Param("type") Integer type);

    Map<String,Object> selectDetails(@Param("helpId") Long helpId);



}
