From: <ny...@us...> - 2007-08-13 08:57:54
|
Update of /cvsroot/tikiwiki/tiki/lib In directory sc8-pr-cvs10.sourceforge.net:/tmp/cvs-serv11713/lib Modified Files: commentslib.php Log Message: [FIX] forums: moderation now worksfor every posts in a moderated forum (only new topics where moderated before). Index: commentslib.php =================================================================== RCS file: /cvsroot/tikiwiki/tiki/lib/commentslib.php,v retrieving revision 1.161 retrieving revision 1.162 diff -u -d -r1.161 -r1.162 --- commentslib.php 10 Aug 2007 13:34:06 -0000 1.161 +++ commentslib.php 13 Aug 2007 08:57:48 -0000 1.162 @@ -502,7 +502,7 @@ /* queue management */ function replace_queue($qId, $forumId, $object, $parentId, $user, $title, $data, $type = 'n', $topic_smiley = '', $summary = '', - $topic_title = '') { + $topic_title = '', $in_reply_to = '') { // timestamp $hash2 = md5($title . $data); @@ -524,22 +524,23 @@ `topic_title`=?, `topic_smiley`=?, `summary` = ?, - `timestamp` = ? + `timestamp` = ?, + `in_reply_to` = ? where `qId`=? "; - $this->query($query,array($object,$parentId,$user,$title,$data,$forumId,$type,$hash2,$topic_title,$topic_smiley,$summary,(int)$this->now,$qId)); + $this->query($query,array($object,$parentId,$user,$title,$data,$forumId,$type,$hash2,$topic_title,$topic_smiley,$summary,(int)$this->now,$in_reply_to,$qId)); return $qId; } else { $query = "insert into `tiki_forums_queue`(`object`, `parentId`, `user`, `title`, `data`, `type`, `topic_smiley`, `summary`, - `timestamp`, `topic_title`, `hash`, `forumId`) - values(?,?,?,?,?,?,?,?,?,?,?,?)"; + `timestamp`, `topic_title`, `hash`, `forumId`, `in_reply_to`) + values(?,?,?,?,?,?,?,?,?,?,?,?,?)"; $this->query($query, array($object, $parentId, $user, $title, $data, $type, $topic_smiley, $summary, (int)$this->now, - $topic_title, $hash2, $forumId)); + $topic_title, $hash2, $forumId, $in_reply_to)); $qId = $this->getOne("select max(`qId`) from `tiki_forums_queue` where `hash`=? and `timestamp`=?",array($hash2,(int)$this->now)); @@ -610,7 +611,7 @@ $threadId = $this->post_new_comment( 'forum:' . $info['forumId'], $info['parentId'], $info['user'], $info['title'], $info['data'], - $message_id, '', //in_reply_to + $message_id, $info['in_reply_to'], $info['type'], $info['summary'], $info['topic_smiley'] ); |