Cancel Registration until 5 days before event

Created on 23 June 2025, 21 days ago

Problem/Motivation

Entity Registration works great! I have set the permissions to allow users to cancel their own registration. This works well until I found that people can cancel their registrations on the day of event and even after the event. This allows them not to be seen as a "no-show" because the system shows they cancelled (even though they cancelled after the event).

Is there a way to limit when someone can cancel their own registration?

Ideally for my use case, I would like to allow them to cancel up until 5 days before the event. After that, I do not wish them to cancel as it will alter use cases. In addition, if there's a waiting list, that promotes someone to normal registration with little time to make arrangements. That also causes confusion.

Steps to reproduce

Set up Entity Registration, change permissions to allow user to cancel registration.

Thanks for all your help!!!

Michael

πŸ’¬ Support request
Status

Active

Version

3.4

Component

Registration Core

Created by

πŸ‡ΊπŸ‡ΈUnited States wattdesigns

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

  • Issue created by @wattdesigns
  • πŸ‡ΊπŸ‡ΈUnited States wattdesigns

    PS..... it would also work so that you can only change Status during the period set up in the registration settings for opening and closing registrations.

  • πŸ‡ΊπŸ‡ΈUnited States john.oltman

    Thanks for the post. This seems like a feature that many users of the module could benefit from. Will work this into the next release.

  • πŸ‡ΊπŸ‡ΈUnited States john.oltman

    I will ensure the "cancel allowed" time period will be configurable.

    I believe the prevention of status updates outside of the open and close dates set in the host entity settings is something that is already implemented, at least for non-admins (admins can always edit, and that needs to stay that way). Please check the global settings at /admin/structure/registration-settings, there is an option there.

  • πŸ‡ΊπŸ‡ΈUnited States wattdesigns

    Yes and no. First off, thanks for pointing out the global admin page that had a check in the "ignore the open and close dates" which I was elated to see! I thought unchecking that would fix everything, but I ran the test below and got poor results. Here's what I did.

    Made a new registration event.
    Enabled the registration.
    Set the Open date to yesterday and the close date to tomorrow.
    On a non-admin account, I checked and registration was open and good.
    I went ahead and registered with the non-admin account.
    Using the admin account, I changed the close date to yesterday (1 minute past the open date).
    On the non-admin, I no longer could register which was great!

    Here's where it gets odd.

    I have a view set up that shows users their registrations. It allows the edit functions with a pull down to allow for edit, cancel, and delete (if given permissions to do so).

    On the non-admin user, with the close date past, they are allowed to cancel their registration using that views interface.

    So, is this more a views issue that I should just not allow that (but I don't see an interface to allow people to cancel their registrations otherwise), or is it a registration thing allowing a cancel outside the open/close dates?

    Let me know if you need me to try anything to test theories.

    Thanks again!!!!

    Michael

  • πŸ‡ΊπŸ‡ΈUnited States john.oltman

    You should have a different option on the global admin page named "Require update access to registrations" - check that, clear cache, and see if the Cancel button goes away for your scenario. I am guessing the non-admin user already lost the Edit access based on your other change.

  • πŸ‡ΊπŸ‡ΈUnited States wattdesigns

    OK, so I've done that testing as well and it still isn't working right (most likely I'm doing something wrong).

    Here's what I did this time.

    On the main admin page, I ensured the following:
    Disregard open and close dates in register access check NOT CHECKED
    Prevent edit of existing registrations when new registration is disabled IS CHECKED
    Require update access to registrations IS CHECKED
    Cleared the cache.

    Set up a new event.
    Set open dates to a few days ago and close to a few days from now. Saved the event.
    Using a non-admin user, I registered for the event.
    Everything looks good.

    Then, using admin account, I edited the event to move the close date to yesterday.
    Cleared the cache again.
    Using non-admin user, I went to the user profile, and the Registrations tab (which is the views page listing registrations for that user)
    Using the Views Operations column, I used the pull down menu to Cancel.
    It asked if I was sure and I confirmed.
    The Status of the registration now shows Cancelled.

    Again, what I'd like is for once the event registration is closed, I do not want users to be able to cancel their registration.

    Thanks again for your help in this!!!

  • πŸ‡ΊπŸ‡ΈUnited States john.oltman

    I followed your steps and it worked properly for me in a test system. What registration related permissions does your non-admin user have?

  • πŸ‡ΊπŸ‡ΈUnited States john.oltman

    Side note: the ability to prevent cancel while registration is still open (e.g. 5 days before it closes) is a separate item that I'm working on as an enhancement. But based on your settings, the Cancel operation should disappear after close, using the current release. Let me know on the permissions and we'll go from there.

  • πŸ‡ΊπŸ‡ΈUnited States wattdesigns

    OK, here's the permissions that I have. Most of the non-admin role permissions are NOT checked. Here are the ones that are checked:

    Administer own registrations View, edit and delete own registrations of this type.

    View own registrations

    View own registrations View own registrations, regardless of type.

    Registration workflow: Use the Cancel transition. Move registrations from Pending, Complete, Waitlist states to Canceled state.

    And that's it. It's so odd!!! Thanks for looking for me!

  • πŸ‡ΊπŸ‡ΈUnited States wattdesigns

    Let me ask this question....how do you allow users to cancel their registration? Does it use a view? I'm just wondering if the view method I'm using is bypassing your system.

  • πŸ‡ΊπŸ‡ΈUnited States john.oltman

    Committed to 3.4.x and will be in the next release. To try it out now, download the dev version of the Registration module and follow the instructions in the README file in the modules/registration_cancel_by folder. I would only use the dev version on a test site.

  • πŸ‡ΊπŸ‡ΈUnited States john.oltman

    Michael, the Cancel operation is added to the operations column of the registration listing - either the Manage Registrations listing for a host entity, or user registrations for a user, or the main listing of all registrations. It does not sound like you are bypassing the transition logic, unless you somehow have a custom operations column. That's ok - this should be a moot point soon with the new submodule I just committed.

  • πŸ‡ΊπŸ‡ΈUnited States wattdesigns

    Ooooooo the new Cancel_by sounds great! I'll see about possibly testing it on a different site. The existing site is used pretty heavily so I'll wait a little bit before the upgrade. EXCITING!!!!

  • πŸ‡ΊπŸ‡ΈUnited States john.oltman

    Thanks for any testing you can do. Just a heads up I am going to add another commit so there is a permission allowing admins to ignore the Cancel by date. Since they may need to be able to cancel at any time for some sites. I'll add that within the next day or two.

Production build 0.71.5 2024