How many sites have you visited that send multiple reminders for an event (one month before, one week before, one day before - and even 1 week after)? Lots, right? It would be great to be able to do this in Drupal. This could be provided by yet another module, but I thought it would be great to slightly tweak Signup to allow this, because the functionality is basically already there. What do you think?

Over the past few days I've been working on a new feature for Signup which would allow the Signup administrator to set a maximum number of configurable reminders, instead of just one. Just like with the current single reminder, defaults could be configured (whether or not to send, how many days in advance, and email message), and these defaults could still also be overridden per-node.
The UI could be basically the same – 'Reminder email 1', 'Reminder email 2' etc.

The basic idea is to not change Signup's DB table structure, except to allow the reminder columns to accept serialized data. Then modify the reminder form in node_settings.inc to repeat to match the number of allowed reminders set in the Signup admin settings. Then tweak all places that submit the form to now serialize the multiple reminder form element data before updating the DB, and unserialize the data in all places that draw from the DB.

Additionally, it would also be great if reminders could be sent x days after the event start date (rather than only before). This configurable email reminder could allow for something like a follow up email (reminding you about the event you just went to), asking for feedback etc. The 'reminder_days_before' DB field could store negative numbers to refer to days after (like a double negative), such as '-7' for 1 week after the event (compared to '7' for 1 week before). "Thank you for coming, please consider filling our feedback form" etc. Rather than forcing people to understand and select negative numbers, a 'before' or 'after' widget could add that logic for reminders after the event.

Attaching a screenshot of the UI, and a (not yet fully working!) patch is coming next. It'd definitely be great to hear what you all think about this, and whether you think this could be a useful feature?

Comments

scottrigby’s picture

Status: Active » Needs work
StatusFileSize
new12.84 KB

Ok, so here's an initial patch. This isn't supposed to work yet, though a lot of it does – the defaults can be saved in admin/settings/signup, but the node-specific overrides don't yet work.

What do you think about the UI, and the feature?

And of course, feedback on what I might be doing wrong – specifically on node_form.inc (around line 51, I think I may be missing something about how this works) – that would be really great!

greggles’s picture

This seems like a great idea to me in general.

We discussed in IRC - here is a summary of my thoughts:

1. I like the idea of sending mails after an event. I often do that.
2. I think "scheduled email" is better than "Reminder email" because a mail after the event is more likely to be a "thanks" than a "reminder."
3. I'd like to give control for the number of reminders to the user creating or editing the node - I think the UI should be something like the cck "add another field" interface though I realize that might be a separate "improve the UI" feature.

dww’s picture

Status: Needs work » Postponed

I can't stand how reminder emails currently work. I haven't looked at the patch in here, but from the description of the issue, I think this is a good idea headed in the wrong direction. ;) We desperately need to address the problems I explain over at #290305: Split out email functionality into separate submodule(s) before anything like this has a prayer of landing upstream...

scottrigby’s picture

StatusFileSize
new14.17 KB

That makes sense. In the meantime, I'd like to get this patch working against the current code (until the new messaging api or submodule solution is further developed). Here is a more developed patch, with help by Jamie – it now successfully saves multiple reminders serialized into the DB, and unserializes the info as needed when retrieving from the DB. The main thing this patch does not yet do is loop through the multiple reminders in cron.inc (still assumes there is only 1 reminder there). So that will need to be modified for this patch to work against the current code - Next installment :)

stborchert’s picture

Just a quick note without deeper thinking on it: isn't it possible to send this type of mails with rules? Especially scheduled rules.
So maybe its better to add rules integration and provide some default rulesets ("send mail x days before [field_start]", "send mail x days after[field_start]", etc.). So you are not limited to a fixed number of reminder or information mails.

thoughts?

Stefan

darsic’s picture

Great idea ... thank you for this patch.
Is there any chance to make this patch 100% working?

Thank you.

scottrigby’s picture

Assigned: Unassigned » scottrigby

@stBorchert: That's a good idea -- though for our needs, we want users to be able to set up multiple reminder emails without having to become trained Rules users, or to have access to the power that comes with the ability to create Rules. For instance, with our approach (like the original feature in Signup) a particular role can have permission to create and manage their own Signup-enabled events, and they can also send a set number of emails to anyone who signs up to their event (a max number set by the site admin, to avoid giving the power of spam, and to simplify the interface for now -- i definitely agree with greggles that an 'Add new' option, similar to multiple cck fields, would be a great UI improvement).

@darsic: we have a working version now, that sends emails appropriately for multiple reminders (before *or* after the event start date). Actually, as greggles also pointed out, 'Reminders' is no longer the best term -- we've changed it to 'Scheduled messages' (rather than 'Scheduled emails', in favor of the more general term). It sounds like eventually this could be handled by the Messaging module, so this was another reason we went with 'Scheduled messages' in our current version.

But also, after talking this over with dww & EclipseGc at Drupalcon, our approach had to be completely reworked anyway. The serialized data approach (cool as it is!) was dropped -- instead we've needed to make a new table {signup_scheduled_messages} which allows a new row for each Scheduled message.

In the next week or so I'll be re-rolling a new patch with our changes against 6--1 (as soon as possible, but we have some other work to do between now & then), and I'll add it here for feedback :)

scottrigby’s picture

StatusFileSize
new30.96 KB

Well, we took slightly longer than a week, but here's a working patch (also worked on heavily by JamesBarger). Aside from what's mentioned farther above, a few other adjustments were made, like placing Scheduled messages in a fieldset (because the repetition of scheduled message forms could get kind of eye-blurring, especially since these forms already look a lot like the confirmation message form!), and some text changes here & there to make it more understandable. So far it seems to work well for us, though it would be great to hear any feedback.

scottrigby’s picture

@dww: referring to #3 above, do you think this could fit with what you describe in this comment from that issue?
http://drupal.org/node/290305#comment-1226604

We could still move the existing email code out into submodules that also implement the appropriate hooks, e.g. signup_reminder.module, etc, for folks that don't want all the complexity (and power) of the entire notifications framework.

With the patch in #8, the signup reminder columns are moved into a new table (though the data isn't literally moved with this patch yet) -- from your comment it sounds like this would be better as it's own signup sub-module (signup_scheduled_messages.module)? I just want to check in with you about that, and see if you have any advice for the best way to go about this if you think it's the best direction.

I'm also curious about the upgrade path - should that be built into this patch (or wait for until it's closer to a solution that you'd consider)? If so I have a question about how to handle the moved columns, similar to miki's comment here: http://drupal.org/node/290305#comment-1238871

Apollo610’s picture

Subscribing - great idea, as I'm looking to implement multiple reminder X DAYS and/or x HOURS...

Just wanted to confirm that any patch/enhancement will include the hours option as well? (ie, receive a message that the poker match you signed up for starts in 6 hours).

Thanks for your work guys!

scottrigby’s picture

@Apollo610: currently the only option is days, but this could probably be made configurable without too much difficulty i assume. Maybe a separate issue though.

@darsic & everyone: BTW, for the cron to fully work there's a few more changes needed in includes/cron.inc (Joining the new table & changing those columns names form reminder to message) & includes/date.inc (just changing which table is looked in). I'll post these changes as a patch once we've got everything working properly. The holdup is we have had deadlines, and merged functionality from a few different patches. I'll have to go back and separate those changes to make a new patch against the current Signup 6.x-1.x.dev. Soon! :)

juicytoo’s picture

Hi scottrigby,

Thanks for this.

I have a situation where I don't have start dates. I use signup for classroom registration.

But I would like to use the reminders to get users to update their registered interest in the signup.

Can I still use this patch?

Ideally, rules integration would be perfect for me, that way I can setup my own schedule events.

Is there someway someone can roll a patch for rules integration. I am happy to fund $100 towards this if it helps. If sure others might want to contribute to this.

Specifically so that I can send emails out to the users after 30 days of signup and then possibly cancel signup upon 60 days if no response of follow up resulted.

thanks in advance.

xsean’s picture

Hi scottrigby,

is there any way to let the user to set their own X number of day to send reminder email before event start?

BenK’s picture

Subscribing...

prometheus2785’s picture

Is there any news on the progress of this patch?? This would be highly benificial to my site, as members are missing the multiple reminders from our previous solution which was meetup.com

d.cox’s picture

Subscribing

gaurzilla’s picture

I have another scenario that would be awesome if its implemented. Perhaps it's already possible, so I'd appreciate any input on whether this can be done.

User_A signs up to be a speaker for a group meeting.

Then 3 days before the event, two actions happen
1. User_A gets a reminder email saying that he/she's signed up, and instructions on where to get a projector etc.
2. All users of the role SomeRole get a slightly different email saying that User_A has signed up and they're all invited.

This should be easy to do if a Signup event can trigger a rule (from Rules module) instead of just sending an email.

etdouglas’s picture

Subscribing

MacaroniDuck’s picture

Subscribing. Is this something still being attended to? Planned to be added to the module? Like others, our group has a serious need for meetup.com style functionality.

dkane’s picture

Wow, this would be some great additional functionality and exactly what I need! I partially installed the patch correctly (on 6.x-1.0), although it didn't add the appropriate table to the database when I ran update.php. Do I need to be running the dev version for this to work? Any updates on how this is going?

Thank you everyone for your work on this and the terrific signup module!

aaron’s picture

Version: 6.x-1.x-dev » 6.x-2.x-dev
Status: Postponed » Needs review
StatusFileSize
new28.67 KB

I am not certain what plans are to get this functionality in place, if any. However, to get things rolling again, I have re-rolled the patch from #8 here, after a little bit of code cleanup.

aaron’s picture

Version: 6.x-2.x-dev » 6.x-1.x-dev

sorry, didn't mean to change the version. This patch is against the 6.x-1.x branch.

scottrigby’s picture

I should mention Signup Reminders in this thread.

The Signup Reminders module allows users to specify multiple reminders (X days, hours or minutes) before or after a Signup in addition to the admin-specified reminder.

dwillcox’s picture

You might check out Date Reminder. I'm not sure that's what you're looking for, but it sounds close.

Though that's reminders for a node, independent of signups.

titel ionescu’s picture

Version: 6.x-1.x-dev » 7.x-1.x-dev