NotspeakService.java 2.21 KB
package com.cnlive.shenhe.service;

import com.cnlive.shenhe.bean.ResponseBean;
import com.cnlive.shenhe.dto.NotSpeakDTO;
import com.cnlive.shenhe.entity.ShyNotspeak;
import com.github.pagehelper.PageInfo;

import java.util.List;

/**
 * @Author: yan-zhao-wang
 * @DateTime: 2022-11-07 9:09
 */
public interface NotspeakService {
    /**
     * 根据条件获取禁言集合列表
     *
     * @param shyNotspeak
     * @return
     */
    List<ShyNotspeak> findShyNotSpeak(ShyNotspeak shyNotspeak);

    /**
     * 根据主键修改禁言 返回布尔类型
     *
     * @param shyNotspeak
     * @return
     */
    boolean updateShyNotSpeak(ShyNotspeak shyNotspeak);

    /**
     * 入禁言对象 返货布尔类型
     *
     * @param shyNotspeak
     * @return
     */
    boolean impotShyNotSpeak(ShyNotspeak shyNotspeak);

    /**
     * 根据评论禁言
     *
     * @param commentId
     * @param time
     * @param userId
     * @return
     */
    ResponseBean notSpeakByComment(Integer commentId, Integer time, String userId);

    /**
     * 查询禁言状态
     *
     * @param commentId
     * @param userId
     * @return
     */
    ResponseBean querySpeakState(Integer commentId, String userId);

    /**
     * 禁言回调
     *
     * @param notSpeakId
     * @param type
     * @param time
     * @param userId
     * @return
     */
    ResponseBean speak(Integer notSpeakId, Integer type, Integer time, String userId);

    /**
     * 根据评论进行禁言
     *
     * @param commentId
     * @param time
     * @param userId
     * @return
     */
    boolean writeNotSpeakByComment(Integer commentId, Integer time, String userId);

    /**
     * 获取禁言分页、条件查询列表
     *
     * @param notSpeakDTO
     * @return
     */
    PageInfo<ShyNotspeak> getPage(NotSpeakDTO notSpeakDTO);

    /**
     * 根据主键id查询禁言对象
     *
     * @param id
     * @return
     */
    ShyNotspeak selectByPrimaryKey(Integer id);

    /**
     * 根据主键修改禁言对象
     *
     * @param shyNotspeak
     * @return
     */
    int updateByPrimaryKeySelective(ShyNotspeak shyNotspeak);

    /**
     * 获取禁言时间
     *
     * @return
     */
    List<ShyNotspeak> getNotSpeakByTime();
}