package com.tmf.bbs.dao;
import com.tmf.bbs.entity.Topic;
import org.apache.ibatis.annotations.ResultMap;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.Update;
import org.apache.ibatis.session.RowBounds;
import java.util.List;
public interface TopicDao {
/**
* 后台帖子管理查询方法(全部帖子)
*
* @param iindexPage
* @return List
*/
List<Topic> queryAll(Integer indexPage);
/**
* 我要发帖具体实现方法
*
* @param topic
* @return
*/
int add(Topic topic);
/**
* 后台修改帖子为精帖
*
* @param topic
* @return
*/
int updateToNice(Topic topic);
/**
* 后台修改帖子不为精帖
*
* @param topic
* @return
*/
int update(Topic topic);
/**
* 全部帖子查询方法
*
* @param row//当前页码数
* @return
*/
@Select("select * from t_topic")
@ResultMap("com.tmf.bbs.mappers.postMap.topicBean")
List<Topic> getAllTopic(RowBounds row);
/**
* 热帖查询方法
*
* @param row//当前页码数
* @return
*/
@Select("select * from t_topic where comment_count>=3 ORDER BY comment_count DESC ")
@ResultMap("com.tmf.bbs.mappers.postMap.topicBean")
List<Topic> getHotTopic(RowBounds row);
/**
* 精帖查询方法
*
* @param row
* @return
*/
@Select("select * from t_topic where nice_topic=1")
@ResultMap("com.tmf.bbs.mappers.postMap.topicBean")
List<Topic> nicePage(RowBounds row);
//首页的热帖
@Select("select * from t_topic where comment_count>=3 ORDER BY comment_count DESC limit 0,10")
@ResultMap("com.tmf.bbs.mappers.postMap.topicBean")
List<Topic> getIndexHotTopic();
//首页的精贴
@Select("select * from t_topic where nice_topic=1 limit 0,10")
@ResultMap("com.tmf.bbs.mappers.postMap.topicBean")
List<Topic> getIndexNiceTopic();
//首页的新帖
@Select("select * from t_topic ORDER BY topic_time DESC limit 0,10")
@ResultMap("com.tmf.bbs.mappers.postMap.topicBean")
List<Topic> getIndexFreshTopic();
/**
* 分页查询帖子
*
* @param topic
* @return
*/
@Select("select count(1) from t_topic")
int countTopic();
/**
* 查询热贴分页
*
* @return
*/
@Select("select count(1) from t_topic where comment_count>=3 ORDER BY comment_count DESC")
int countTopicByHot();
/**
* 查询精品贴分页
*
* @return
*/
@Select("select count(1) from t_topic where nice_topic=1")
int countTopicByNice();
/**
* 新帖查询方法
*
* @param indexPage
* @return
*/
List<Topic> newPage(Integer indexPage);
/**
* 删除方法
*
* @param topic
* @return
*/
int delete(Topic topic);
/**
* 根据userId 来查询个人的帖子
*
* @param userId
* @param currentPage
* @return List<Topic>
*/
List<Topic> queryByUserId(Integer userId, Integer currentPage);
/**
* 根据topicId查询帖子的具体信息
*
* @param topicId
* @return
*/
@Select("select * from t_topic where id=#{id}")
@ResultMap("com.tmf.bbs.mappers.postMap.topicBean")
Topic queryByTopicId(Integer topicId);
/**
* 根据topicId更新帖子中的Comment_count的值
*
* @param topicId
* @return
*/
@Update("update t_topic set comment_count=comment_count-1 where id=#{topicId}")
int updateCommment_count(Integer topicId);
}
没有合适的资源?快使用搜索试试~ 我知道了~
课设项目基于springboot框架搭建的bbs论坛系统源码+sql数据库(含登录及各种帖子功能).zip
共345个文件
js:80个
png:79个
java:37个
1.该资源内容由用户上传,如若侵权请联系客服进行举报
2.虚拟产品一经售出概不退款(资源遇到问题,请及时私信上传者)
2.虚拟产品一经售出概不退款(资源遇到问题,请及时私信上传者)
版权申诉
0 下载量 51 浏览量
2023-10-16
17:24:28
上传
评论
收藏 3.59MB ZIP 举报
温馨提示
【资源说明】 课设项目基于springboot框架搭建的bbs论坛系统源码+sql数据库(含登录及各种帖子功能).zip 课设项目基于springboot框架搭建的bbs论坛系统源码+sql数据库(含登录及各种帖子功能).zip 课设项目基于springboot框架搭建的bbs论坛系统源码+sql数据库(含登录及各种帖子功能).zip 课设项目基于springboot框架搭建的bbs论坛系统源码+sql数据库(含登录及各种帖子功能).zip 课设项目基于springboot框架搭建的bbs论坛系统源码+sql数据库(含登录及各种帖子功能).zip 【备注】 1、该资源内项目代码都经过测试运行成功,功能ok的情况下才上传的,请放心下载使用! 2、本项目适合计算机相关专业(如计科、人工智能、通信工程、自动化、电子信息等)的在校学生、老师或者企业员工下载使用,也适合小白学习进阶,当然也可作为毕设项目、课程设计、作业、项目初期立项演示等。 3、如果基础还行,也可在此代码基础上进行修改,以实现其他功能,也可直接用于毕设、课设、作业等。 欢迎下载,沟通交流,互相学习,共同进步!
资源推荐
资源详情
资源评论
收起资源包目录
课设项目基于springboot框架搭建的bbs论坛系统源码+sql数据库(含登录及各种帖子功能).zip (345个子文件)
ueditor.css 41KB
ueditor.min.css 33KB
video-js.css 21KB
video-js.min.css 11KB
shCoreDefault.css 8KB
video.css 4KB
scrawl.css 4KB
codemirror.css 3KB
charts.css 3KB
image.css 2KB
attachment.css 2KB
index.css 2KB
emotion.css 2KB
music.css 2KB
dialogbase.css 2KB
edittable.css 1KB
background.css 1KB
template.css 1KB
manage.css 671B
register.css 580B
login.css 556B
manager_left.css 467B
help.css 389B
iframe.css 41B
vjs.eot 3KB
UEditorSnapscreen.exe 508KB
wface.gif 49KB
jxface2.gif 40KB
yface.gif 28KB
bface.gif 27KB
icons.gif 20KB
tface.gif 19KB
fface.gif 18KB
cface.gif 8KB
icons-all.gif 4KB
videologo.gif 2KB
cancelbutton.gif 1KB
button-bg.gif 1KB
lock.gif 1KB
word.gif 1019B
icon_doc.gif 1012B
icon_psd.gif 1009B
icon_rar.gif 1007B
icon_xls.gif 1005B
icon_mv.gif 1001B
icon_ppt.gif 1001B
icon_pdf.gif 996B
icon_mp3.gif 986B
icon_txt.gif 970B
icon_exe.gif 949B
icon_chm.gif 923B
cursor_v.gif 370B
cursor_h.gif 253B
anchor.gif 184B
icon_ok.gif 177B
wrong.gif 115B
highlighted.gif 111B
unhighlighted.gif 111B
bg.gif 84B
pagebreak.gif 54B
spacer.gif 43B
0.gif 43B
.gitignore 0B
image.html 12KB
index.html 6KB
attachment.html 6KB
map.html 6KB
wordimage.html 6KB
emotion.html 6KB
show.html 5KB
charts.html 5KB
video.html 5KB
link.html 4KB
insertframe.html 4KB
searchreplace.html 4KB
gmap.html 4KB
scrawl.html 4KB
background.html 3KB
help.html 3KB
edittable.html 2KB
webapp.html 2KB
snapscreen.html 2KB
anchor.html 2KB
edittd.html 2KB
preview.html 1KB
music.html 950B
template.html 922B
edittip.html 863B
spechars.html 829B
TopicDao.java 4KB
PostServicesImpl.java 3KB
PostController.java 2KB
UserDao.java 2KB
UserServicesImpl.java 2KB
AnnounceServicesImpl.java 2KB
CommentDao.java 1KB
User.java 1KB
Pages.java 1KB
TopicServicesImpl.java 1KB
TopicController.java 1KB
共 345 条
- 1
- 2
- 3
- 4
资源评论
Make程序设计
- 粉丝: 5725
- 资源: 3570
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功