Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Notify driver when ride is cancelled #77

Closed
AlexGilleran opened this issue Nov 7, 2020 · 0 comments
Closed

Notify driver when ride is cancelled #77

AlexGilleran opened this issue Nov 7, 2020 · 0 comments

Comments

@AlexGilleran
Copy link
Member

AlexGilleran commented Nov 7, 2020

Note that this depends on #76 so that we can actually send the email!

When a ride is cancelled by a facilitator, if a driver has already accepted it then that driver needs to be notified, otherwise they won't know that they're not supposed to turn up for the ride!

In order to achieve this, we need to make it so that when ride is cancelled by a facilitator, and it's already been claimed by a driver, the driver automatically gets an email to let them know.

The email should be something like:

Subject: Ride for {client_name} has been cancelled

Hi {driver_name},

This email is to let you know that  that the ride you accepted for {client_name} from {from_address} to {to_address} is no longer needed and has been cancelled. If you'd like to give a ride to someone else, <a href={link to find a ride}>look to see if there's any rides needed</a>.

Thanks,
Hills Carpal.

Because we record the driver's email directly against a ride right now, we should be able to get this done without any of the user synchronisation stuff in #78, although if it's done before #78 it might need a bit of an update to use whatever new database structure comes about as a result of completing that issue.

Criteria

  • When a facilitator cancels a ride:
    • If the ride has already been accepted by a driver, that driver gets the email above
    • If the ride has not been accepted by anyone, nothing additional happens
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant