mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-04-20 10:52:14 +09:00
#19688372 delete voted comment log, when comment deleted
git-svn-id: http://xe-core.googlecode.com/svn/branches/1.5.0@8299 201d5d3c-b55e-5fd7-737f-ddc643e51545
This commit is contained in:
parent
b8b78cb986
commit
dac37ebf53
2 changed files with 35 additions and 3 deletions
|
|
@ -369,6 +369,9 @@
|
|||
}
|
||||
}
|
||||
|
||||
$this->_deleteDeclaredComments($args);
|
||||
$this->_deleteVotedComments($args);
|
||||
|
||||
// commit
|
||||
$oDB->commit();
|
||||
|
||||
|
|
@ -408,18 +411,39 @@
|
|||
// Delete a list of comments
|
||||
$output = executeQuery('comment.deleteCommentsList', $args);
|
||||
|
||||
//delete declared, declared_log
|
||||
//delete declared, declared_log, voted_log
|
||||
if(is_array($commentSrlList) && count($commentSrlList)>0)
|
||||
{
|
||||
unset($args);
|
||||
$args->comment_srl = join(',', $commentSrlList);
|
||||
$tmpOutput1 = executeQuery('comment.deleteDeclaredComments', $args);
|
||||
$tmpOutput2 = executeQuery('comment.deleteCommentDeclaredLog', $args);
|
||||
$this->_deleteDeclaredComments($args);
|
||||
$this->_deleteVotedComments($args);
|
||||
}
|
||||
|
||||
return $output;
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief delete declared comment, log
|
||||
* @param $commentSrls : srls string (ex: 1, 2,56, 88)
|
||||
* @return void
|
||||
**/
|
||||
function _deleteDeclaredComments($commentSrls)
|
||||
{
|
||||
executeQuery('comment.deleteDeclaredComments', $commentSrls);
|
||||
executeQuery('comment.deleteCommentDeclaredLog', $commentSrls);
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief delete voted comment log
|
||||
* @param $commentSrls : srls string (ex: 1, 2,56, 88)
|
||||
* @return void
|
||||
**/
|
||||
function _deleteVotedComments($commentSrls)
|
||||
{
|
||||
executeQuery('comment.deleteCommentVotedLog', $commentSrls);
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief Increase vote-up counts of the comment
|
||||
**/
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue