Synopsis


Drupal Provides facility to delete comments with its type(Approved/Unapproved) by checking each comment manually.
Comment Bulk Delete Module is useful for delete the comments with the date range , content type and comment type.

Features


Comment Deletion can be possible by the following Criteria
1. Date Range : By selecting Start and End Date, You can delete comments for your required date range
2. Content Type: You can Select content type for delete comments. (Multiple Content type Selection also possible)
3. Comment Type: You can select comment type Approved/Unapproved for delete Comments

Configuration


1. Copy the entire comment_bulk_delete module directory and place it inside the
Drupal sites/all/modules directory.
2. Login as an administrator.
Enable the module in the "Administrator" -> "Modules" -> "Others"

Project Space

This is the Link for
Bulk Comment Delete

Git Clone Repository Setup

git clone --branch 7.x-1.x http://git.drupal.org/sandbox/Vimalavinisha/2556435.git comment_bulk_delete
cd comment_bulk_delete

Pareview results:

http://pareview.sh/pareview/httpgitdrupalorgsandboxvimalavinisha2556435git

CommentFileSizeAuthor
#2 comment-bulk-delete.png57.08 KBVimala vinisha

Comments

Vimala vinisha created an issue. See original summary.

Vimala vinisha’s picture

StatusFileSize
new57.08 KB
Vimala vinisha’s picture

Assigned: Vimala vinisha » Unassigned
Vimala vinisha’s picture

Issue summary: View changes
Vimala vinisha’s picture

Issue summary: View changes
Vimala vinisha’s picture

Issue summary: View changes
Vimala vinisha’s picture

Issue summary: View changes
Vimala vinisha’s picture

Issue summary: View changes
Vimala vinisha’s picture

Issue summary: View changes
pravin ajaaz’s picture

Project: [D7] Comment Bulk Delete » Drupal.org security advisory coverage applications
Component: Code » module
Status: Active » Needs review
Vimala vinisha’s picture

Issue summary: View changes
Vimala vinisha’s picture

Issue summary: View changes
Vimala vinisha’s picture

Title: Comment Bulk Delete » [D7] Comment Bulk Delete
PA robot’s picture

Multiple Applications
It appears that there have been multiple project applications opened under your username:

Project 1: https://www.drupal.org/node/2557637

Project 2: https://www.drupal.org/node/2532176

As successful completion of the project application process results in the applicant being granted the 'Create Full Projects' permission, there is no need to take multiple applications through the process. Once the first application has been successfully approved, then the applicant can promote other projects without review. Because of this, posting multiple applications is not necessary, and results in additional workload for reviewers ... which in turn results in longer wait times for everyone in the queue. With this in mind, your secondary applications have been marked as 'closed(duplicate)', with only one application left open (chosen at random).

If you prefer that we proceed through this review process with a different application than the one which was left open, then feel free to close the 'open' application as a duplicate, and re-open one of the project applications which had been closed.

I'm a robot and this is an automated message from Project Applications Scraper.

PA robot’s picture

Status: Needs review » Needs work

There are some errors reported by automated review tools, did you already check them? See http://pareview.sh/pareview/httpgitdrupalorgsandboxVimalavinisha2556435git

We are currently quite busy with all the project applications and we prefer projects with a review bonus. Please help reviewing and put yourself on the high priority list, then we will take a look at your project right away :-)

Also, you should get your friends, colleagues or other community members involved to review this application. Let them go through the review checklist and post a comment that sets this issue to "needs work" (they found some problems with the project) or "reviewed & tested by the community" (they found no major flaws).

I'm a robot and this is an automated message from Project Applications Scraper.

Vimala vinisha’s picture

Issue summary: View changes
Vimala vinisha’s picture

Vimala vinisha’s picture

Status: Needs work » Needs review
Vignesh Puliyadi Raja’s picture

Status: Needs review » Needs work

Automated Review

Review of the 7.x-1.x branch (commit 56d737a):

No automated test cases were found, did you consider writing Simpletests or PHPUnit tests? This is not a requirement but encouraged for professional software development.

Manual Review

Coding style
(+) comment_bulk_delete_install(): Why do you call check_plain() here, its just a static text? Remove it.
You should also really have a hook_help() with some basic info about the module.

After submit the comment delete, I am getting the success message like this.

%count Comments Deleted Successfully. Need to be address this first.

Vimala vinisha’s picture

Hi Vignesh PR,

Thanks for your great review.
1. hook_help has been added in the module file
2. check_plain() function has been removed from .install file
3. "%count Comments Deleted Successfully" This is also fixed.

Vimala vinisha’s picture

Status: Needs work » Needs review
pravin ajaaz’s picture

Status: Needs review » Needs work

The automated review looks almost clean. Great work !!

Suggestions based on the initial Manual Review:

In install file

1. The variable $t you created, should be used as :

drupal_set_message($t('Comment Bulk Delete Module has been successfully installed'));

This might fix the single error which the pareview shows.

In module file

Here more work needs to be done, actually 2 specifc things :

1. You should use comment_delete_multiple API function instead of deleting the comments using dynamic queries in the function comment_bulk_delete_delete_comment

You can fetch the comment ID ($cids) as an array based on the conditions selected by the user and pass it to the comment_delete_multiple.

2. What the module would do if there are about 1,000 comments? This process might be timed out. So You should make use of Batch API.

3. check_plain is used only to sanitize user entered data before displaying it. You don't need it in comment_bulk_delete_form_validate and comment_bulk_delete_form_submit functions.

Vimala vinisha’s picture

Hi Pravin,

Thanks for reviewing. As per your suggestions, I have modified both .install & .module files .

Vimala vinisha’s picture

Status: Needs work » Needs review
pravin ajaaz’s picture

Status: Needs review » Reviewed & tested by the community

Thanks. All the reviews seem to be addressed, so changing the status to RTBC. Spend time to review other's module so that your module will be reviewed by a Git admin soon!!

Vimala vinisha’s picture

Priority: Normal » Major
damienmckenna’s picture

Status: Reviewed & tested by the community » Fixed

Thanks for your contribution, Vimala!

I updated your account so you can promote this to a full project and also create new projects as either a sandbox or a "full" project.

Here are some recommended readings to help with excellent maintainership:

You can find lots more contributors chatting on IRC in #drupal-contribute. So, come hang out and stay involved!

Thanks, also, for your patience with the review process. Anyone is welcome to participate in the review process. Please consider reviewing other projects that are pending review. I encourage you to learn more about that process and join the group of reviewers.

Thanks to the dedicated reviewer(s) as well.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.

Vignesh Puliyadi Raja’s picture