Project link: https://drupal.org/sandbox/uniwales/2100301
Git: git clone http://git.drupal.org/sandbox/uniwales/2100301.git
Reviews of other projects
Block Headline: https://drupal.org/node/2097475#comment-7914143
Twitter Embedded Timeline: https://drupal.org/node/2092233#comment-7914153
Drag & Drop Blocks: https://drupal.org/node/2095707#comment-7914127
Overview
Anonymous Date Reminder re-factors the Date Reminder module to allow anonymous visitors to request an email reminder to be sent at a specified time before an event. Generally these would be calendar events, but any node type that has any datetime field can support reminders.
Features
How this module differs from Date Reminder
This module does not integrate with Drupal's user system. It does not link reminders to users, it allows anonymous visitors to request reminders. In addition to the above change, this module:
- Shows tabs only to users with the permission to view all reminders on a node.
- Shows 'Send test email' only to users who can administer anonymous date reminders.
- Allows reminder form to be displayed in a table and as unformatted fields
- Creates a block that can be used to place the reminder form in a region using the block ui
Apart from the above, this module uses the code from and stays true to the original Date Reminder Module.
When reminders are enabled for a node, anonymous visitors can request reminders to be sent before each occurrence of the date/time. The visitor specifies how long before the date/time to send the reminder.
When reminders are enabled for a node type, anyone who can edit the node can enable or disable reminders for that node.
Reminders are sent using Drupal's email system.
System administrator can control:
- Which node types allow reminders, and which date field (if there are several) in a type to use as the basis of reminders.
- Which users can see or administer reminders.
- Content of reminder messages.
- If and how long reminders should be kept after last date occurrence.
- The list of allowed lead times for reminders from which users can select.
Known Issues
- If you use one of the administrator options to delete a group of reminders, there isn't any kind of "Are you sure you want to do that?" verification. There should be.
- Reminders won't work well if the requested "lead time" is less than the cron period, especially less than half the cron period. If cron runs infrequently on your site you'll probably want to remove the options for short remind times.
Why Not Patch Date Reminder?
The changes necessary to make Date Reminder work for anonymous users required too many changes for a patch to be a reasonable solution. The maintainer for Date Reminder has not shown interest in allowing this functionality, possibly because of the amount of code that needed to be rewritten in order to allow for anonymous users. We tried to integrate anonymous reminders with the current user based reminders, but found that we needed to undo too much of the original to be able to produce something workable within our time constraints. Although, ideally, this would have been a collaboration, it was not possible. Although the basics of the module are very similar; the ability for anonymous users to request reminders seemed sufficiently different and valuable enough for us to warrant spending a little more time making this module releasable.
Coder Error
Coder highlights the following:
anon_datereminder.module
severity: normalreview: style_function_spacingLine 487: Functions should be called with no spaces between the function name and opening parentheses [style_function_spacing]
$countemails = array_filter($reminders, function($reminder) use ($email) {My callback function looks proper. I am not sure if coder does not have the appropriate rule in place to handle callback functions within function calls or if I am missing something.
Comments
Comment #0.0
batdesign commentedremoving repeating overview field
Comment #0.1
batdesign commentedcorrecting repository link
Comment #0.2
batdesign commentedmoving links to top of form
Comment #0.3
batdesign commentedchanging branch to 7.x-1.x
Comment #1
bletch commentedInstalled and tested on fresh Drupal 7, everything ran as expected. Automated tests picked up some problems with legacy code from Date Reminder I fixed and committed. Automated tests are now clear.
Comment #2
PA robot commentedWe 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.
Comment #2.0
PA robot commentedfixing clone link
Comment #3
batdesign commentedRequesting review bonus
Comment #3.0
batdesign commentedAdding reviewed projects section
Comment #4
willyk commentedI agree with your logic around the need for a new project as opposed to trying to build this into the Date Reminder module. Although perhaps the modules could perhaps eventually be integrated.
After running the module through Coder, it appears that a space should likely be added within the array on line 236 of anon_datereminder.admin.inc:
'#token_types' => array('anon_datereminder','node'),If you remove that space it will eliminate the error generated by the Coder module.
Also note that on line 73 of mailer.inc, you should include enclose within a t() so that it is translatable by the [i18n_8] module:
drupal_set_message('email is required', 'error');Line 73: The $message argument to drupal_set_message() should be enclosed within t() so that it is translatable. [i18n_8]
drupal_set_message('email is required', 'error');
I also suggest revising your ReadMe documentation slightly by expanding on the installation process and confirming that Date and Token are required modules.
Comment #5
batdesign commented@willyk - Thank you for reviewing. Coder issues are fixed and readme is updated.
Comment #6
willyk commentedDid you see the other issue that arises when you run you module through the Code module? I'm wondering if perhaps there's a way to code this differently so that it doesn't raise a warning.
Also note that on line 299 & 300 the spacing/tabs need to be adjusted based on the report from the Coder module:
Comment #7
batdesign commentedHello,
Yeah, we run code cleanup automatically and it missed a few of the conversions. The last commit was clean using coder.
Thank you, again.
Comment #7.0
batdesign commentedediting Why not patch Date Reminder
Comment #7.1
batdesign commentedadding note for send test email change
Comment #8
jojototh commentedHello, I found small coder issues in the latest version of code:
this one should be fixed.
There is also following two
but these are probably cause be strange syntax of anonymous function, and not recognized example tag.
And also I would prefer to have all hooks in module file to be on the top of file, and the custom functions on the bottom.
Otherwise it looks fine.
Comment #9
peter.milan commentedComment #10
peter.milan commentedSorry, for mistake.
Comment #11
jojototh commentedChanging status.
Comment #11.0
jojototh commentedcoder highlighting callback function note
Comment #12
candotri commentedThis is really minor but could you please put the full git clone command into your issue summary? I didn't know the name of your module so when I git cloned it I had to figure it out. It just makes the project two steps easier to review. Thanks!
git clone http://git.drupal.org/sandbox/uniwales/2100301.git anon_datereminderA direct link to your pareview.sh results would also help:
http://pareview.sh/pareview/httpgitdrupalorgsandboxuniwales2100301git
Your README.txt is well written and easy to follow. Good work.
You use constants far more than I typically see in Drupal modules. I don't see anything wrong with that but it sure sticks out!
It seems that you could reduce the size of your .module file even more by moving some of the functions out. I'm thinking of some of those internal functions.
Has this been tested with sites using MIMEmail and other such modules? That's quite common.
The code is readable and seems logical. The documentation is logical and easy to understand.
Good work!
Candotri
Comment #13
batdesign commentedComment #14
batdesign commentedComment #15
batdesign commentedHave updated the issue to reviewed and tested as the only issue is coder's incorrect error. Please let me know if there are any code problems that would keep this from being accepted.
Comment #16
klausiplease don't RTBC your own issues, see the project application workflow: https://drupal.org/node/532400
Comment #17
xiukun.zhou commentedgreat work.
There are only two small problems
1. Your GIT file tree should not contain .DS_Store file http://drupalcode.org/sandbox/uniwales/2100301.git/tree
2. Why is two % in Hook_uninstall http://drupalcode.org/sandbox/uniwales/2100301.git/blob/HEAD:/anon_dater...
Comment #18
sk2013 commentedNice Idea and Great Work. When this work will be available as a module for use?
Thanks,
Senthil
Comment #19
PA robot commentedClosing due to lack of activity. Feel free to reopen if you are still working on this application (see also the project application workflow).
I'm a robot and this is an automated message from Project Applications Scraper.
Comment #20
batdesign commentedComment #21
klausiReview of the 7.x-1.x branch:
This automated report was generated with PAReview.sh, your friendly project application review script. You can also use the online version to check your project. You have to get a review bonus to get a review from me.
manual review:
Those are not critical application blockers, otherwise I would say this is RTBC. Removing review bonus tag, you can add it again if you have done another 3 reviews of other projects.
Assigning to MiSc as he might have time to take a final look at this.
Comment #22
misc commentedAfter cleanup this is ready to go, as far as I can see.
Comment #23
sk2013 commentedWhen this would be available as a module ? Looking forward at an early date.
Thanks
Comment #24
batdesign commentedI am going to implement the relevant parts of klausi's review this week.
Comment #25
batdesign commentedLatest push addresses all of the issues raised by Klausi. Please let me know if anything else needs to be corrected before this can be moved to a full on project.
Thanks.
Comment #26
klausino objections for more than a week, so ...
Thanks for your contribution, batdesign!
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.
Comment #27
sk2013 commentedThanks batdesign for your good work on this module. I really appreciate this.
Thanks also to klausi for his untiring effort on the review process. People like you are an asset to the Open Source Community.
I am not a technical / Development resource and your dedication makes me to inspire and regret my inability to code or doing a code review. However, I can help in testing the functionality.
Klausi's guide on the review process will inspire many others.. I am sure.
Thanks again
Comment #29
toni.degroof commentedSince I got no answer on the forum I try to reach somebody here.
I can install date reminder and it works on my sie. I de-install Date Reminder and install Anonymous Date Reminder. I see no errors, but The fields don't show. I emptied the cache several times, tried a block, no result.
What am I doing wrong?