Closed (fixed)
Project:
Entity Registration
Version:
3.0.x-dev
Component:
Registration Confirmation
Priority:
Normal
Category:
Feature request
Assigned:
Unassigned
Reporter:
Created:
22 May 2023 at 12:43 UTC
Updated:
13 Jun 2023 at 22:59 UTC
Jump to comment: Most recent
Comments
Comment #2
john.oltman commentedDid you run cron after the registration was completed? You have to run cron to get the scheduled actions to execute.
Comment #3
neubreed commentedHi there John. Yes I ran the cron and nothing happened.
Comment #4
john.oltman commentedI'm going to need more than this. Questions:
* Your install sends emails otherwise - like the password reset?
* You ran cron within one hour of the completion date/time?
* There is a valid email association with the registration?
* Anything in the logs?
Comment #5
selecta commentedHow can i configure drupal to run cron right after a registration? My current setting is 3 hours and the fastest would be 1 hour.
But in general on the subject: It should be even faster than 1min. I don't understand why there can't be an immediate confirmation email.
thx
Comment #6
neubreed commentedHi John. I think the problem was with my mail configuration. There was nothing in the logs to indicate that it failed to send. Only when the email was successfully sent.
I agree with selecta in that it would be great to have the scheduled action be triggered after a user registers. The hosting platform I use only runs the cron once an hour which I can't change unfortunately. An instant email confirmation is something that would be useful / common.
Comment #7
neubreed commentedSome further information ..
I've set the the registration schedule to 1 minute after Registration completed
Person registers at 05/26/2023 - 13:23
Multiple manual cron runs:
05/26/2023 - 13:30 Cron run completed.
05/26/2023 - 13:30
05/26/2023 - 13:30
05/26/2023 - 13:31
05/26/2023 - 13:31
05/26/2023 - 13:32
05/26/2023 - 13:32
05/26/2023 - 13:33
05/26/2023 - 13:34
registration_scheduled_action 05/26/2023 - 13:37 Sent registration confirmation email to matt@… neubreed
smtp 05/26/2023 - 13:37 Sending mail to: matt@.....com.au (…
Comment #8
john.oltman commentedThanks for the additional info. Scheduled actions cannot be scheduled with greater frequency than Cron runs. The interface lets you do it since it doesn't know how often Cron will run, but the reality is if Cron runs every hour, then that is the highest frequency you can get on your actions. In a shared hosting environment, a confirmation message that comes an hour later isn't what you want, I get that. The D7 module had none of this functionality so this is all add-on for D10. You are right that an immediate confirmation would be preferred. I'm going to change this to a Feature Request and see what I can do on that.
Comment #9
john.oltman commentedComment #10
john.oltman commentedComment #11
john.oltman commentedComment #13
john.oltman commentedComment #14
john.oltman commentedComment #15
neubreed commentedHi John,
Thanks for working on this so quickly . I've had a play with the new submodule and my registration default state is set to "Complete" and I don't think the EventSubscriber onUpdate is executed when someone registers. If I login to the admin and edit the registration the onUpdate event subscriber is executed
if (($from_state !== $to_state) && $registration->isComplete()) {By this point my from_state and to_state are both complete. So the email doesn't get sent
It would be good if the email gets sent on insert without admin intervention
Comment #16
john.oltman commented@neubreed - I realized the same thing soon after my initial commit - and pushed up some fixes after that. If you grab the latest Dev branch, it will handle your use case now (on insert) without admin intervention.