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

country/state chain-select behavior is broken in Event Cart Checkout "add another participant"

    Details

    • Type: Bug
    • Status: Done/Fixed
    • Priority: Minor
    • Resolution: Fixed/Completed
    • Affects Version/s: 4.7.9
    • Fix Version/s: 4.7.11
    • Component/s: None
    • Labels:
    • Documentation Required?:
      None
    • Funding Source:
      Contributed Code

      Description

      To reproduce:

      1. Enable Event Cart Checkout functionality.
      2. Create an event with online registration using a profile that includes Country and State fields.
      3. Visit the event information page for this event and click "Add to Cart", then visit the cart checkout page.
      4. Observe that for the first (existing) contact, the chain-select behavior of Country and State fields is correct.
      5. Click the "Add Another Participant" link and wait for the additional participant fields to be created; observe that State field has no options, and will continue to have none, even after changing the Country field selection, as shown here:
      6. Submit the form leaving any required fields empty, so that the form is reloaded with errors; on the reloaded form, observe that, for both participants, the chain-select behavior of Country and State fields is correct.

      This appears to be happening because the code that builds the HTML snippet for the added participant fails to call the preProcessChainSelectFields() method on the form object.

      I have a PR in hand and will post it shortly.

        Attachments

          Activity

            People

            • Assignee:
              allenshaw Allen Shaw
              Reporter:
              allenshaw Allen Shaw
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: