* Upgrade Django to 3.0 and other dependencies to recent versions
* Fix otp version contsraint
* Remove six dependency
* Resolve some warnings
* Fix failing tests
* Update django-countries
* Resolve all RemovedInDjango31Warnings in test suite
* Run isort
* Fix import
* Update PostgreSQL version on travis
* Stripe SCA
- Upgrade to latest Stripe API
- Deprecate Stripe Checkout for CC
- Migrate CC payments to Payment Intents
* Move SCA to its own view
* Handle CardErrors for PaymentIntents
* Abilty to handle charge webhooks with PaymentIntents
* Better handling of Stripe References
* Fix Stripe Tests
* Move SCA page into orderlayout; perform iFrame SCA
* Handle disputes and pi-webhooks better, fill more into ReferencedStripeObject
* Optionally pass prefetched PaymentIntent to handle-func
* Fix style
* Send message to window.parent not window.top (widget compatibility)
* More accurate loading message
* Show a cog on sca_return.html. On a good internet connection, you barely see it, but on a bad one…
* Robust error handling
* If it's a method and used like a method, let's actually call it like a method!
* Remove logging statement
* Fix JavaScript interference with other frame events
* Use 4:3 aspect ratio, but at least 600px
* Adjust to django_scopes
As discussed, this is a WIP for integrating Stripe's Payment Request Buttons (with also includes the ApplePay-Button on iOS-devices).
Todos:
- [x] Payment Request Button is still displayed, even when a card has already been tokenized (when going back in the order-flow)
- [x] The domains used need to be verified using the Stripe API to enable ApplePay: https://stripe.com/docs/stripe-js/elements/payment-request-button#verifying-your-domain-with-apple-pay
- [x] Migration: Get the account-country for existing Stripe Connect users
- [x] Migration: Verify the domains using the above mentioned API for existing users
- [x] Converting the chargeable amount is not right for non-decimal currencies like JPY
Other considerations:
- On iOS-devices using Safari (probably also on MacBooks, etc. - not tested), the [regular payment request button](https://user-images.githubusercontent.com/157270/38515749-f53f8392-3be9-11e8-8917-61ef78dd354a.png) is automatically replaced with a [buy with Apple Pay button](https://docs-assets.developer.apple.com/published/094d0eb90e/988c36a8-a43c-4ff9-85ef-beda16c4b7c9.png).
- On all other platforms, the generic payment request button is displayed. Even if the device supports a specific payment provider like Google Pay, Microsoft Wallet, Samsung Pay, etc., the generic button will first offer the cards saved within the webbrowser in addition to the other payment methods. Only upon selecting the specific payment provider like GPay, the corresponding payment flow is started.
- Right now, the rendering of the payment button is completely in the hands of Stripe. Once pretix takes on the task of doing this, we should try to detect if the browser supports well known payment methods like GPay in addition to the browser-saved cards. If that's the case, we should add the corresponding marks onto the "Pay Now"-Button (like [this](https://developers.google.com/pay/api/images/brand-guidelines/google-pay-mark.png), [this](https://assets.pcmag.com/media/images/490984-samsung-pay.png?width=1600&height=900), or [this](https://www.firstffcu.com/images/MS-Wallet_stacked_rgb_grey.png)), so the customer can identify the purpose of the button easier.
- [x] Also, all of this is still based against the pretix 1.x codebase ;-)
* check for payment method instead of order total
* incorporate payment fee diff in totaldiff at oder change
* use fee from model and the correct order total
* add error handling
* do not change paid orders
* OrderChangedManager can only be committed once
* remove prints of stripe secrets
* add tests
* an OrderChangeManager must not be committed multiple times
* A pending free order stays pending after being changed
* comments on paid_to_free logic