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

Obsidian Registration Expired Discount Codes Throwing Exception #5430

Closed
1 task done
Jon-Corey opened this issue May 2, 2023 · 0 comments
Closed
1 task done

Obsidian Registration Expired Discount Codes Throwing Exception #5430

Jon-Corey opened this issue May 2, 2023 · 0 comments
Labels
Fixed in v14.3 Fixed in v15.1 Priority: High Affects most production Rock installs in a way that will be noticed. Topic: Event Registration Related to Rock Event Registration. Type: Bug Confirmed bugs or reports that are very likely to be bugs.

Comments

@Jon-Corey
Copy link
Contributor

Jon-Corey commented May 2, 2023

Please go through all the tasks below

  • Check this box only after you have successfully completed both the above tasks

Please provide a brief description of the problem. Please do not forget to attach the relevant screenshots from your side.

When creating registrations for camps, we often have a series of discount codes for early registrations that expire before we expect final payment. On these registrations we do not require the total cost to be payed as soon as the registration is completed. This means that we often have people that used a discount code on their registration go back to make an additional payment on their registration after the discount code has expired.Previously, on the C# block, it would allow them to make the additional payment and it would keep the existing discount, even though the discount code is now expired. This is the expected result.The Obsidian block does not seem to have anticipated needing to be able to use expired discount codes and so when someone goes to make a payment on an existing registration that has an expired discount code, the block throws an unhandled NullReferenceException and redirects the user to an error page.The error page that is shown:

ObsidianRegistrationExpiredDiscountCodesThrowingExceptionError## Expected Behavior
Trying to make a payment on a registration with a discount code that was valid at the time, but has since expired should present the user with a payment screen that allows them to make additional payments. The existing discount code should still apply, even if it has expired since the registration was initially filled out.## Actual Behavior
Trying to make a payment on a registration with a discount code that was valid at the time, but has since expired presents the user with an error page.## Steps to Reproduce

  1. Create a registration template
  2. In the Details section, set the Financial Gateway to the "Test Gateway"
  3. In the Details section, set the Cost to $10 and set the Minimum Initial Payment to $1
  4. In the Discounts section, create a new discount with the following configuration:
  • Discount Code: "test"
  • Discount Percentage: 50%
  • Effective Dates:
  • Start: Any time in the past
  • End: Any time in the future
  1. Create an instance of the registration
  2. Go to a page with the Obsidian Registration Entry block with the registration instance id in the URL as a page parameter
  3. Select any number of registrants and hit "Next"
  4. Fill in the First Name and Last Name fields and hit "Next"
  5. Fill in the Discount Code field with "test" and hit "Apply" to apply the "test" discount
  6. Fill in the Amount To Pay Today field with "$1" and hit "Next"
  7. Fill in the Credit Card field with "0000 0000 0000 0000"
  8. Navigate to the /MyAccount page (or any page with the Registration List Lava block)
  9. On the Registration List Lava block, select the registration you just filled out
    ObsidianRegistrationExpiredDiscountCodesThrowingExceptionReproduce
  10. Notice how you are able to view your remaining balance and how you are able to pay it off
  11. Go to the registration template and change the expire date for the discount to any time in the past to simulate the expiration date passing
  12. Navigate back to the /MyAccount page (or any page with the Registration List Lava block)
  13. On the Registration List Lava block, select the registration you filled out
  14. Notice how you see an error page that says there was a NullReferenceException in Rock.Blocks

Rock Version

14.3 (Although this is an issue from v13 - present)## Client Culture Setting
en-US

Jon-Corey added a commit to Jon-Corey/Rock that referenced this issue May 2, 2023
@ethan-sparkdevnetwork ethan-sparkdevnetwork added Type: Bug Confirmed bugs or reports that are very likely to be bugs. Priority: High Affects most production Rock installs in a way that will be noticed. Topic: Event Registration Related to Rock Event Registration. Fixed in v14.3 labels Jun 13, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Fixed in v14.3 Fixed in v15.1 Priority: High Affects most production Rock installs in a way that will be noticed. Topic: Event Registration Related to Rock Event Registration. Type: Bug Confirmed bugs or reports that are very likely to be bugs.
Projects
None yet
3 participants