Details
Description
Users at GLPA have reported the following bugs with Change Selections and Record Payment functionality. I've re-confirmed on my test sandbox.
Recreating these requires the following setup:
- Create a price set with 2 fields: required Main Fee (radio buttons) field and an optional Workshops field (checkboxes). Set a low Max Participants value on one of the Workshops (e.g. 2). Screenshot example attached.
- Create an event using this Price Set - allow pay later.
- Install CiviDiscount from master branch
- Create a discount against the price field options and the event
- Register 2 participants using front-end registration with pay later.
==============================
1. Using 'Change Selections' screen for registrations with discounted options is definitely broken. The discounted line-item value (price) is ignored in the form values - they have the full prices. If you then save the form even w/o making any changes the line_item totals are over-written with the full price. (see ExistingDiscountsIgnoredInChangeSelectionsForm.PNG)
NOTE: I don't think it matters whether you're dealing with a Paid or Pending/Pay Later registration. In either case, the discounts are 'lost' when changing selections.
2.1 Using 'Change Selections' screen for registrations where one or more of the selected CHECKBOX options is FULL results in an incorrect value for Total Owed. The calculation ignores the FULL option (which is a read-only checkbox). This throws off the total owing. (see FullOptionsIgnoredInBalanceCalc.PNG)
2.2 If the price field uses a SELECT html_type for a price field value that has a limit on Max Participants, when attempting to use the 'Change Selections' form for an already registered participant the form rule error saying the option is sold out is triggered incorrectly. We should not trigger that form rule on the selected option when the participant is ALREADY registered and using one of the counted instances (see IncorrectSoldOutErrorInChangeSelectionsDropdown.PNG)
3. Using the Edit Participant form to record a received payment for a Pending Pay Later does not properly record the payment record (i.e. go to Edit participant and check the 'Record Payment' checkbox and set payment status to Completed and save). The contribution is updated to Completed in this flow but the View / Edit form doesn't show Paid Balance (Total Paid shows as $0) and you can not 'View Payments' . (see RecordPaymentUsingEditParticipant_TotalPaidZero.PNG)
NOTE: If you record the received payment via Edit Contribution, then the financial transaction is recorded properly and when you view the Participant the Total Paid and Balance are correct.
Attachments
Issue Links
- is supplemented by
-
CRM-15380 Change Selections postProcess: erroneously updates contribution status to Completed and inserts line_items with NULL contribution_id
- Done/Fixed
-
CRM-15377 On changing price field option(s) from 'Change Fee Selection' doesn't update lineitem's label and unit_price
- Done/Fixed