Uploaded image for project: 'CiviCRM'
  1. CiviCRM
  2. CRM-17151

Contribution Status moves to "Pending Refund" when Event Participation Balance becomes zero because the section changes

    Details

    • Versioning Impact:
      Patch (backwards-compatible bug fixes)
    • Documentation Required?:
      None
    • Funding Source:
      Needs Funding

      Description

      This issue is related to CRM-16868.

      Short story. It is possible to change the event selections in such a way that the balance becomes 0. The associated contribution status should go to 'Completed', but it moved instead to 'Pending refund.' Fix: make the contribution status change to 'Completed' in this context.

      To reproduce

      I configured an event with no payment processors and the pay later option enabled. This is typical for a small Dutch conference, payments are done with electronic bank transfer and registered manual. The event has priceset configured with one mandatory and one optional component.

      Now I execute the following actions.
      A participants registers online for only the mandatory component.
      In CiviCrm a registration is created with the status "Pending from pay later"
      and a connected Contribution with the status "Pending (Pay Later)"

      Now the payment is recorded in the backoffice by using the "Edit Event Registration Screen" -> Pay Later Option.
      I set the payment status to completed

      I get a confirmation screen and I agree. The associated contribution also moves to completed.

      The participant status is still "Pending from Pay later" but I manually change it to Registered.

      So far, so good.

      But now I change the selection of the registration to add the optional component of the event.

      In the production situation this the processing of a email that the participant also wants the optional component. (Or even a bank transfer, where in the remark field the optional component is selected).

      The Event Registration gets now the status partially paid, and the same happens for the contribution. bug CRM-16868 is fixed.

      But now there is regret. The participant does not want the extra component (maybe a mistake in the communication). So it is deselected again and the balance returns to 0.

      But the Contribution moves to pending refund, and this cannot be corrected anymore.

      I attach a screenshot with my the test case on demo.civicrm.org

        Attachments

        1. CRM-17151.png
          129 kB
          Klaas Eikelboom
        2. patch.diff
          8 kB
          Klaas Eikelboom

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              keikelboom Klaas Eikelboom
            • Votes:
              1 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

              • Created:
                Updated: