TransactionEntryv2 block charges CC percent for ACH transactions
Description
When not using a saved person account and entering payment details, the TransactionEntryv2 block calculates the fee coverage amount for ACH using the gateway's CC fee percentage when fee coverage default state is set to Yes in the block settings and the person opts not to cover the fees by unchecking the checkbox in ACH.
Actual Behavior
See steps to reproduce for screenshots of observed faulty behavior
Faulty Code
In ConfigureCoverTheFees method, when the fee coverage default state is yes, both ACH and CC fee coverage checkboxes are explicitly checked by default upon initial load of the block
When landing on ACH screen, entering the details, and unchecking the fee coverage and clicking next, the account summary text is updated with a total amount exhibiting the issue since it calls the GetSelectedFeeCoverageAmount method which has the bug causing the code to use the CC percentage and charge user a wrong fee coverage amount for ACH when they opted not to be charged at all
Code Fix
The code needs to change and add an additional condition in the else for negating the isAch value
Expected Behavior
When the user opts not to cover fees, no fee coverage is charged especially not the wrong amount
Steps to Reproduce
Default coverage state is set to Yes
Proceed to payment info step and land on the ACH currency type panel and uncheck the fee coverage checkbox
Click next and the account summary changes to include a 1.75% CC percentage fee which is what is configured in our My Well gateway settings
Note: Since the Test Gateway doesn't have support for showing ACH controls you will not observe this behavior using that gateway. You will have to use a proper gateway that display ACH controls like My Well to see this issue.
Issue Confirmation
- [X] Perform a search on the Github Issues to see if your bug or enhancement is already reported.
- [X] Try to reproduce the problem on a fresh install or on the demo site.
Rock Version
16.0
Client Culture Setting
en-US