提交 e0d0f403 编写于 作者: huangxuan258's avatar huangxuan258

修复文章评论数和文章显示的不一致问题

上级 05d93ef7
......@@ -919,7 +919,8 @@ class Topic extends CI_Controller {
$commentlist = $this->articlecomment_model->list_by_tid ( $tid, 1, $startindex, $pagesize );
$commentrownum = returnarraynum ( $this->db->query ( getwheresql ( "articlecomment", " tid=$tid AND state=1 ", $this->db->dbprefix ) )->row_array () );
//更新评论数
$this->db->where(array('id'=>$tid))->update('topic',array('articles'=>$commentrownum));
$departstr = page ( $commentrownum, $pagesize, $page, "topic/getone/$topicid" );
// if(is_mobile()){
// include template('getonetopic','wap');
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册