dao层修改 单元测试

This commit is contained in:
禾几海
2020-05-25 13:50:11 +08:00
parent 190e1624ca
commit 9185ff8f58
3 changed files with 210 additions and 72 deletions

View File

@@ -8,8 +8,8 @@ import java.util.List;
/**
* @Author: 小海
* @Date 2019/06/30 16:19
* @Description
* @Date: 2019/06/30 16:19
* @Description:
*/
@Mapper
@Repository
@@ -18,11 +18,9 @@ public interface CommentMapper {
int updateContent(String content, long id);
int updateResponder(String responder, long id);
int delete(long id);
int deleteByArticleId(long articleId);
int deleteByPagePath(String pagePath);
boolean existsById(long id);
@@ -30,19 +28,13 @@ public interface CommentMapper {
Comment getLastestComment();
List<Comment> findAllByAuthorIDAndType(long id, boolean isComment);
List<Comment> findAllByFromUser(long id);
List<Comment> findAllByPId(long pid);
List<Comment> findAllByPid(long pid);
List<Comment> findAllByArticleID(long articleId);
List<Comment> findAllByPagePath(String pagePath);
List<Comment> findAllByArticleIDAndPId(long articleID, long pid);
List<Comment> findAllByPagePathAndPid(String pagePath, long pid);
List<Comment> findCommentsByTypeAndPId(boolean isComment, long pid);
List<Comment> findAllByPId(int pid);
List<Comment> findAllByType(boolean isComment);
long countByType(boolean isComment);
long countByPagePath(String pagePath);
}