Incorrect calculation of $applyToAllLineItems causes payment section to be hidden incorrectly
To reproduce:
- Configure an event for
- online registration
- multiple participants
- price set containing multiple separate fields with amounts > 0
- Configure a discount to apply 100% discount only to all options in one of the price fields (i.e., this discount does not apply to some of the fields)
- Navigate the online registration form
- Select 2 participants
- Enter the discount code and Apply Discount
Observe:
- Good: The discount is applied to the appropriate field options. Therefore, some options have $0.00 amount, and others have amounts > 0.
- Bad: The payment method fields are hidden. The only way to make it display is to change "Number of Participants" to 1. Otherwise, no amount of clicking (even of price fields with amounts > 0) can cause them to be displayed.
This appears to be caused by incorrect logic for setting $applyToAllLineItems
in !275 (merged) (pinging @mattwire)
See also: !288 which describes a different problem with a similar cause.
[Joinery internal reference: F#1071]
Edited by AllenShaw