Skip to content

#380 - update civi address if donor updates their postal code

DaveD requested to merge DaveD/stripe:readonly into master

See #380 (closed)

  1. If it's a newer install, turn off the setting at admin - civicontribute - stripe settings that hides the billing fields.
  2. Log in as a user who has a billing address with a postal code filled in.
  3. Go to a donation page. I tested with both webform and a civicrm contribution page.
  4. In the credit card widget, start entering a card. When the postal code appears, change it.
  5. Continue filling out the form as normal.
  6. In the civi billing field at the bottom, it will appear as though the postal code has updated. But this is an html disabled field so will not get submitted to the server. This is easier to see with a contribution page that uses a confirmation page, since when you get to the confirmation page it will still show the old postal code.
  7. If you complete the donation, you'll see that the address in civi has not been updated on the contact.

Solution: Change from using disabled to readonly.

By comparison, if you are not logged in and your dedupe rule matches, then currenly it does update the postal code if you enter a different one than is already in civi, so this makes it consistent with that too.

Merge request reports