mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-04-29 15:22:15 +09:00
스패머 처리시 댓글이 휴지통으로 들어가지 않는 문제 수정
스패머 처리시 휴지통 이동을 기본값으로 함
This commit is contained in:
parent
c5138ab477
commit
ca5eb517cf
2 changed files with 20 additions and 11 deletions
|
|
@ -3681,9 +3681,7 @@ class memberController extends member
|
|||
$module_srl = Context::get('module_srl');
|
||||
$cnt_loop = Context::get('cnt_loop');
|
||||
$proc_type = Context::get('proc_type');
|
||||
$isMoveToTrash = true;
|
||||
if($proc_type == "delete")
|
||||
$isMoveToTrash = false;
|
||||
$isMoveToTrash = ($proc_type !== 'delete') ? true : false;
|
||||
|
||||
// check grant
|
||||
$columnList = array('module_srl', 'module');
|
||||
|
|
@ -3692,8 +3690,6 @@ class memberController extends member
|
|||
|
||||
if(!$grant->manager) throw new Rhymix\Framework\Exceptions\NotPermitted;
|
||||
|
||||
$proc_msg = "";
|
||||
|
||||
// delete or trash destination
|
||||
// proc member
|
||||
if($cnt_loop == 1)
|
||||
|
|
@ -3774,7 +3770,7 @@ class memberController extends member
|
|||
*
|
||||
* @return object
|
||||
**/
|
||||
protected function _spammerDocuments($member_srl, $isMoveToTrash)
|
||||
protected function _spammerDocuments($member_srl, $isMoveToTrash = true)
|
||||
{
|
||||
$oDocumentController = getController('document');
|
||||
$oCommentController = getController('comment');
|
||||
|
|
@ -3791,7 +3787,14 @@ class memberController extends member
|
|||
$commentList = CommentModel::getCommentListByMemberSrl($member_srl, $columnList, 0, false, $getContentsCount);
|
||||
if($commentList) {
|
||||
foreach($commentList as $v) {
|
||||
$oCommentController->deleteComment($v->comment_srl, true, $isMoveToTrash);
|
||||
if($isMoveToTrash)
|
||||
{
|
||||
$oCommentController->moveCommentToTrash($v);
|
||||
}
|
||||
else
|
||||
{
|
||||
$oCommentController->deleteComment($v->comment_srl, true);
|
||||
}
|
||||
}
|
||||
}
|
||||
} elseif($cnt_document > 0) {
|
||||
|
|
@ -3799,8 +3802,14 @@ class memberController extends member
|
|||
$documentList = DocumentModel::getDocumentListByMemberSrl($member_srl, $columnList, 0, false, $getContentsCount);
|
||||
if($documentList) {
|
||||
foreach($documentList as $v) {
|
||||
if($isMoveToTrash) $oDocumentController->moveDocumentToTrash($v);
|
||||
else $oDocumentController->deleteDocument($v->document_srl);
|
||||
if($isMoveToTrash)
|
||||
{
|
||||
$oDocumentController->moveDocumentToTrash($v);
|
||||
}
|
||||
else
|
||||
{
|
||||
$oDocumentController->deleteDocument($v->document_srl, true);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue